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 6 pull requests #39694

Merged
merged 13 commits into from
Feb 10, 2017
Merged

Rollup of 6 pull requests #39694

merged 13 commits into from
Feb 10, 2017

Commits on Feb 7, 2017

  1. Unignore u128 test for stage 0,1

    Even more SNAP cleanup.
    est31 committed Feb 7, 2017
    Configuration menu
    Copy the full SHA
    ddb0a78 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    e5396e0 View commit details
    Browse the repository at this point in the history

Commits on Feb 9, 2017

  1. Configuration menu
    Copy the full SHA
    0dbdb2d View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    d113b39 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    b8b8980 View commit details
    Browse the repository at this point in the history
  4. Fix indentation in test.

    solson committed Feb 9, 2017
    Configuration menu
    Copy the full SHA
    2589f4a View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    5eaa7c2 View commit details
    Browse the repository at this point in the history
  6. Rollup merge of rust-lang#39604 - est31:i128_tests, r=alexcrichton

    Unignore u128 test for stage 0,1
    
    Even more SNAP cleanup.
    
    Follow-up of rust-lang#39519.
    
    Sorry, I didn't check twice.
    frewsxcv authored Feb 9, 2017
    Configuration menu
    Copy the full SHA
    a05cc5c View commit details
    Browse the repository at this point in the history
  7. Rollup merge of rust-lang#39619 - michaelwoerister:rename-crate-metad…

    …ata, r=alexcrichton
    
    Choose different name for metadata obj-file to avoid clashes with user-chosen names.
    
    Fixes rust-lang#39585 and probably rust-lang#39508.
    Incremental compilation assigns different names to obj-files than regular compilation. If a crate is called "metadata" this can lead to a clash between the root module's obj-file and the obj-file containing crate-metadata. This PR assigns a name to the metadata obj-file that cannot clash with other obj-file because it contains a `.` which is not allowed in a Rust module identifier.
    
    r? @alexcrichton
    
    cc @nikomatsakis
    frewsxcv authored Feb 9, 2017
    Configuration menu
    Copy the full SHA
    3eaca41 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    711b95f View commit details
    Browse the repository at this point in the history
  9. Rollup merge of rust-lang#39678 - vadimcn:top-level-expn, r=michaelwo…

    …erister
    
    Exclude top-level macro expansions from source location override.
    
    It occurred to me that a simple heuristic can address the issue rust-lang#36382: any macros that expand into items (including `include!()`) don't need to be stepped over because there's not code to step through above a function scope level.
    
    r? @michaelwoerister
    frewsxcv authored Feb 9, 2017
    Configuration menu
    Copy the full SHA
    7bd0da7 View commit details
    Browse the repository at this point in the history
  10. Rollup merge of rust-lang#39682 - solson:fix-unaligned-read, r=eddyb

    Fix unsafe unaligned loads in test.
    
    r? @eddyb
    cc @Aatch @nikomatsakis
    
    The `#[derive(PartialEq, Debug)]` impls on a packed struct contain undefined behaviour. Both generated impls take references to unaligned fields, which will fail to compile once we correctly treat that as unsafe (see rust-lang#27060).
    
    This UB was found by running the test under [Miri](https://github.com/solson/miri/) which rejects these unsafe unaligned loads. 😄
    
    Here's a simpler example:
    
    ```rust
    struct Packed {
        a: u8,
        b: u64,
    }
    ```
    
    It expands to:
    
    ```rust
        fn fmt(&self, __arg_0: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
            match *self {
                Packed { a: ref __self_0_0, b: ref __self_0_1 } => { // BAD: these patterns are unsafe
                    let mut builder = __arg_0.debug_struct("Packed");
                    let _ = builder.field("a", &&(*__self_0_0));
                    let _ = builder.field("b", &&(*__self_0_1));
                    builder.finish()
                }
            }
        }
    ```
    
    and
    
    ```rust
        fn eq(&self, __arg_0: &Packed) -> bool {
            match *__arg_0 {
                Packed { a: ref __self_1_0, b: ref __self_1_1 } => // BAD: these patterns are unsafe
                match *self {
                    Packed { a: ref __self_0_0, b: ref __self_0_1 } => // BAD: these patterns are unsafe
                    true && (*__self_0_0) == (*__self_1_0) &&
                        (*__self_0_1) == (*__self_1_1),
                },
            }
        }
    ```
    frewsxcv authored Feb 9, 2017
    Configuration menu
    Copy the full SHA
    7e2b2f3 View commit details
    Browse the repository at this point in the history
  11. Rollup merge of rust-lang#39683 - solson:fix-unaligned-load-librustc_…

    …metadata, r=bluss
    
    Fix unaligned load in librustc_metadata::index.
    
    The derived `Clone` impl contains UB and will be unsafe when we fix rust-lang#27060. See [this comment](rust-lang#27060 (comment)) for more context.
    
    r? @bluss
    frewsxcv authored Feb 9, 2017
    Configuration menu
    Copy the full SHA
    55c17a5 View commit details
    Browse the repository at this point in the history