Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rollup of 7 pull requests #65952

Closed
wants to merge 26 commits into from
Closed

Commits on Oct 26, 2019

  1. Update comments re type parameter hack in object safety

    To check if a method's receiver type is object safe, we create a new receiver type by substituting in a bogus type parameter (let's call it `U`) for `Self`, and checking that the unmodified receiver type implements `DispatchFromDyn<receiver type with Self = U>`. It would be better to use `dyn Trait` directly, and the only reason we don't is because it triggers another check that `Trait` is object safe, resulting in a query cycle. Once the feature `object_safe_for_dispatch` (tracking issue rust-lang#43561) is stabilized, this will no longer be the case, and we'll be able to use `dyn Trait` as the unsized `Self` type. I've updated the comments in object_safety.rs accordingly.
    mikeyhew authored Oct 26, 2019
    Configuration menu
    Copy the full SHA
    fb4095d View commit details
    Browse the repository at this point in the history

Commits on Oct 27, 2019

  1. Configuration menu
    Copy the full SHA
    e216b65 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    93c5639 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    d56ab6d View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    160791b View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    7d6f869 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    e42800b View commit details
    Browse the repository at this point in the history

Commits on Oct 28, 2019

  1. Configuration menu
    Copy the full SHA
    58b67c8 View commit details
    Browse the repository at this point in the history

Commits on Oct 29, 2019

  1. Configuration menu
    Copy the full SHA
    4479de4 View commit details
    Browse the repository at this point in the history
  2. ci: upload toolstates.json to rust-lang-ci2

    Uploading the toolstate data for each commit will help our release
    tooling understand which components are failing, to possibly skip
    shipping broken tools to users.
    pietroalbini committed Oct 29, 2019
    Configuration menu
    Copy the full SHA
    0200050 View commit details
    Browse the repository at this point in the history
  3. Apply suggestions from lzutao

    Co-Authored-By: lzutao <taolzu@gmail.com>
    pietroalbini and tesuji authored Oct 29, 2019
    Configuration menu
    Copy the full SHA
    bdfcde4 View commit details
    Browse the repository at this point in the history
  4. Optimize long-linker-command-line test

    Replace O(n^3) text matching with inexpensive hash set lookups.
    
    On my machine this reduces the total runtime of complete
    run-make-fulldeps suite from roughly 75 seconds to 45 seconds.
    tmiasko committed Oct 29, 2019
    Configuration menu
    Copy the full SHA
    afbb89e View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    c3521fe View commit details
    Browse the repository at this point in the history
  6. review comments

    estebank committed Oct 29, 2019
    Configuration menu
    Copy the full SHA
    ef2a853 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    6998085 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    9ae0c1d View commit details
    Browse the repository at this point in the history
  9. Fix NLL test

    estebank committed Oct 29, 2019
    Configuration menu
    Copy the full SHA
    a3b8687 View commit details
    Browse the repository at this point in the history
  10. Silence crate external span error in x86 platforms

    This causes issues in at least `dist-i586-gnu-i586-i686-musl`,
    possibly others.
    estebank committed Oct 29, 2019
    Configuration menu
    Copy the full SHA
    213fd1f View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    08ca236 View commit details
    Browse the repository at this point in the history

Commits on Oct 30, 2019

  1. Rollup merge of rust-lang#65068 - estebank:trait-impl-lt-mismatch, r=…

    …nikomatsakis
    
    Custom lifetime error for `impl` item doesn't conform to `trait`
    
    Partly addresses rust-lang#42706, rust-lang#41343, fix rust-lang#40900.
    tmandry authored Oct 30, 2019
    Configuration menu
    Copy the full SHA
    ab9b789 View commit details
    Browse the repository at this point in the history
  2. Rollup merge of rust-lang#65112 - jack-t:type-parens-lint, r=varkor

    Add lint and tests for unnecessary parens around types
    
    This is my first contribution to the Rust project, so I apologize if I'm not doing things the right way.
    
    The PR fixes rust-lang#64169. It adds a lint and tests for unnecessary parentheses around types. I've run `tidy` and `rustfmt` &mdash; I'm not totally sure it worked right, though &mdash; and I've tried to follow the instructions linked in the readme.
    
    I tried to think through all the variants of `ast::TyKind` to find exceptions to this lint, and I could only find the one mentioned in the original issue, which concerns types with `dyn`. I'm not a Rust expert, thought, so I may well be missing something.
    
    There's also a problem with getting this to build. The new lint catches several things in the, e.g., `core`. Because `x.py` seems to build with an equivalent of `-Werror`, what would have been warnings cause the build to break. I got it to build and the tests to pass with `--warnings warn` on my `x.py build` and `x.py test` commands.
    tmandry authored Oct 30, 2019
    Configuration menu
    Copy the full SHA
    da5d7a7 View commit details
    Browse the repository at this point in the history
  3. Rollup merge of rust-lang#65241 - tmiasko:no-std-san, r=nikomatsakis

    build-std compatible sanitizer support
    
    ### Motivation
    
    When using `-Z sanitizer=*` feature it is essential that both user code and
    standard library is instrumented. Otherwise the utility of sanitizer will be
    limited, or its use will be impractical like in the case of memory sanitizer.
    
    The recently introduced cargo feature build-std makes it possible to rebuild
    standard library with arbitrary rustc flags. Unfortunately, those changes alone
    do not make it easy to rebuild standard library with sanitizers, since runtimes
    are dependencies of std that have to be build in specific environment,
    generally not available outside rustbuild process. Additionally rebuilding them
    requires presence of llvm-config and compiler-rt sources.
    
    The goal of changes proposed here is to make it possible to avoid rebuilding
    sanitizer runtimes when rebuilding the std, thus making it possible to
    instrument standard library for use with sanitizer with simple, although
    verbose command:
    
    ```
    env CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_RUSTFLAGS=-Zsanitizer=thread cargo test -Zbuild-std --target x86_64-unknown-linux-gnu
    ```
    
    ### Implementation
    
    * Sanitizer runtimes are no long packed into crates. Instead, libraries build
      from compiler-rt are used as is, after renaming them into `librusc_rt.*`.
    * rustc obtains runtimes from target libdir for default sysroot, so that
      they are not required in custom build sysroots created with build-std.
    * The runtimes are only linked-in into executables to address issue rust-lang#64629.
      (in previous design it was hard to avoid linking runtimes into static
      libraries produced by rustc as demonstrated by sanitizer-staticlib-link
      test, which still passes despite changes made in rust-lang#64780).
    * When custom llvm-config is specified during build process, the sanitizer
      runtimes will be obtained from there instead of begin rebuilding from sources
      in src/llvm-project/compiler-rt. This should be preferable since runtimes
      used should match instrumentation passes. For example there have been nine
      version of address sanitizer ABI.
    
    Note this marked as a draft PR, because it is currently untested on OS X (I
    would appreciate any help there).
    
    cc @kennytm, @japaric, @Firstyear, @choller
    tmandry authored Oct 30, 2019
    Configuration menu
    Copy the full SHA
    e9022da View commit details
    Browse the repository at this point in the history
  4. Rollup merge of rust-lang#65274 - pietroalbini:ci-upload-toolstate, r…

    …=alexcrichton
    
    Upload toolstates.json to rust-lang-ci2
    
    This PR does two things:
    
    * Following up with rust-lang#65202, it migrates deploying artifacts to CI in a script. Both uploading release artifacts and CPU stats were merged into the same script, designing it to be easily extended.
    * Uploads the toolstate JSON to `rust-lang-ci2` along with the release artifacts, both for Linux and Windows. This is needed because @RalfJung wants to stop shipping MIRI when its tests are failing, and the toolstate repo doesn't have entries for each commit. Having the toolstate data (just for that specific commit) on `rust-lang-ci2` will simplify the code a lot.
    
    r? @alexcrichton
    cc @RalfJung
    tmandry authored Oct 30, 2019
    Configuration menu
    Copy the full SHA
    2004e09 View commit details
    Browse the repository at this point in the history
  5. Rollup merge of rust-lang#65850 - mikeyhew:patch-1, r=nikomatsakis

    Update comments re type parameter hack in object safety
    
    To check if a method's receiver type is object safe, we create a new receiver type by substituting in a bogus type parameter (let's call it `U`) for `Self`, and checking that the unmodified receiver type implements `DispatchFromDyn<receiver type with Self = U>`. It would be better to use `dyn Trait` directly, and the only reason we don't is because it triggers another check that `Trait` is object safe, resulting in a query cycle. Once the feature `object_safe_for_dispatch` (tracking issue rust-lang#43561) is stabilized, this will no longer be the case, and we'll be able to use `dyn Trait` as the unsized `Self` type. I've updated the comments in object_safety.rs accordingly.
    
    cc @Centril @nikomatsakis @bovinebuddha
    tmandry authored Oct 30, 2019
    Configuration menu
    Copy the full SHA
    d34aa17 View commit details
    Browse the repository at this point in the history
  6. Rollup merge of rust-lang#65914 - estebank:type-alias-bounds-sugg, r=…

    …davidtwco
    
    Use structured suggestion for unnecessary bounds in type aliases
    tmandry authored Oct 30, 2019
    Configuration menu
    Copy the full SHA
    40f8f56 View commit details
    Browse the repository at this point in the history
  7. Rollup merge of rust-lang#65945 - tmiasko:long-linker-command-line, r…

    …=alexcrichton
    
    Optimize long-linker-command-line test
    
    Replace O(n^3) text matching with inexpensive hash set lookups.
    
    On my machine this reduces the total runtime of complete
    run-make-fulldeps suite from roughly 75 seconds to 45 seconds.
    tmandry authored Oct 30, 2019
    Configuration menu
    Copy the full SHA
    167a8f5 View commit details
    Browse the repository at this point in the history