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 10 pull requests #57075

Closed
wants to merge 30 commits into from
Closed

Rollup of 10 pull requests #57075

wants to merge 30 commits into from

Commits on Dec 17, 2018

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

Commits on Dec 18, 2018

  1. Configuration menu
    Copy the full SHA
    f731445 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    c2402dc View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    d6969ac View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    0309874 View commit details
    Browse the repository at this point in the history

Commits on Dec 19, 2018

  1. Remove TokenStream::JointTree.

    This is done by adding a new `IsJoint` field to `TokenStream::Tree`,
    which simplifies a lot of `match` statements. And likewise for
    `CursorKind`.
    
    The commit also adds a new method `TokenTree:stream()` which can replace
    a choice between `.into()` and `.joint()`.
    nnethercote committed Dec 19, 2018
    Configuration menu
    Copy the full SHA
    e7c5146 View commit details
    Browse the repository at this point in the history

Commits on Dec 20, 2018

  1. Copyrite

    oli-obk committed Dec 20, 2018
    Configuration menu
    Copy the full SHA
    405d8b0 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    59f643f View commit details
    Browse the repository at this point in the history

Commits on Dec 21, 2018

  1. Configuration menu
    Copy the full SHA
    cdbccf5 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f8e508c View commit details
    Browse the repository at this point in the history
  3. Also test projections

    oli-obk committed Dec 21, 2018
    Configuration menu
    Copy the full SHA
    b9d74fc View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    3414be0 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    6ed596e View commit details
    Browse the repository at this point in the history
  6. Fix alignment for array indexing

    We need to reduce the alignment with the used offset. If the offset
    isn't known, we need to reduce with the element size to support
    arbitrary offsets.
    nikic committed Dec 21, 2018
    Configuration menu
    Copy the full SHA
    097d39d View commit details
    Browse the repository at this point in the history

Commits on Dec 23, 2018

  1. enum type instead of variant suggestion unification

    Weirdly, we were deciding between a help note and a structured
    suggestion based on whether the import candidate span was a dummy—but
    we weren't using that span in any case! The dummy-ness of the span
    (which appears to be a matter of this-crate vs. other-crate
    definition) isn't the right criterion by which we should decide
    whether it's germane to mention that "there is an enum variant";
    instead, let's use the someness of `def` (which is used as the
    `has_unexpected_resolution` argument to `error_code`).
    
    Since `import_candidate_to_paths` has no other callers, we are free to
    stop returning the span and rename the function. By using
    `span_suggestions_`, we leverage the max-suggestions output limit
    already built in to the emitter, thus resolving rust-lang#56028.
    
    In the matter of message wording, "you can" is redundant (and perhaps
    too informal); prefer the imperative.
    zackmdavis committed Dec 23, 2018
    Configuration menu
    Copy the full SHA
    3986c96 View commit details
    Browse the repository at this point in the history
  2. adjust enum type instead of variant suggestions for prelude enums

    The present author regrets not thinking of a more eloquent way to do
    this.
    zackmdavis committed Dec 23, 2018
    Configuration menu
    Copy the full SHA
    64ad3e2 View commit details
    Browse the repository at this point in the history
  3. Remove dead code

    estebank committed Dec 23, 2018
    Configuration menu
    Copy the full SHA
    2820dc8 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    b42a3ac View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    bd1d5bc View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    7ae6fb2 View commit details
    Browse the repository at this point in the history
  7. Rollup merge of rust-lang#56188 - zackmdavis:if_i_may_suggest, r=davi…

    …dtwco
    
    enum type instead of variant suggestion unification
    
    Fixes rust-lang#56028.
    
    Weirdly, we were deciding between a help note and a structured suggestion based on whether the import candidate span was a dummy—but we weren't using that span in any case! The dummy-ness of the span (which appears to be a matter of this-crate vs. other-crate definition) isn't the right criterion by which we should decide whether it's germane to mention that "there is an enum variant"; instead, let's use the someness of `def` (which is used as the `has_unexpected_resolution` argument to `error_code`).
    
    Since `import_candidate_to_paths` has no other callers, we are free to stop returning the span and rename the function. By using `span_suggestions_`, we leverage the max-suggestions output limit already built in to the emitter, thus resolving rust-lang#56028.
    
    In the matter of message wording, "you can" is redundant (and perhaps too informal); prefer the imperative.
    
    In a second commit, we do some unprincipled special-casing to correct and beautify suggestions for `Option` and `Result` (where the existing code was being confused by their being reexported in the prelude).
    
    r? @davidtwco
    Centril committed Dec 23, 2018
    Configuration menu
    Copy the full SHA
    cd93b16 View commit details
    Browse the repository at this point in the history
  8. Rollup merge of rust-lang#56916 - oli-obk:static_mut_beta_regression,…

    … r=davidtwco
    
    Fix mutable references in `static mut`
    
    fixes rust-lang#56903
    Centril committed Dec 23, 2018
    Configuration menu
    Copy the full SHA
    d9bad38 View commit details
    Browse the repository at this point in the history
  9. Rollup merge of rust-lang#56917 - sinkuu:mir_build_logicop, r=davidtwco

    Simplify MIR generation for logical operations
    
    Reduces one block and one branch from MIR generated for a logical operator.
    Centril committed Dec 23, 2018
    Configuration menu
    Copy the full SHA
    6fa0b0a View commit details
    Browse the repository at this point in the history
  10. Rollup merge of rust-lang#56953 - oli-obk:dead_const, r=petrochenkov

    Mark tuple structs as live if their constructors are used
    
    fixes rust-lang#56281
    Centril committed Dec 23, 2018
    Configuration menu
    Copy the full SHA
    99f4ce2 View commit details
    Browse the repository at this point in the history
  11. Rollup merge of rust-lang#56964 - nnethercote:TokenStream-IsJoint, r=…

    …petrochenkov
    
    Remove `TokenStream::JointTree`.
    
    This is done by adding a new `IsJoint` field to `TokenStream::Tree`,
    which simplifies a lot of `match` statements. And likewise for
    `CursorKind`.
    
    The commit also adds a new method `TokenTree:stream()` which can replace
    a choice between `.into()` and `.joint()`.
    Centril committed Dec 23, 2018
    Configuration menu
    Copy the full SHA
    3a5e4da View commit details
    Browse the repository at this point in the history
  12. Rollup merge of rust-lang#56966 - varkor:raw-pointer-deref-parens, r=…

    …zackmdavis
    
    Correct strings for raw pointer deref and array access suggestions
    
    Fixes rust-lang#56714.
    Fixes rust-lang#56963.
    
    r? @zackmdavis
    Centril committed Dec 23, 2018
    Configuration menu
    Copy the full SHA
    d875fcd View commit details
    Browse the repository at this point in the history
  13. Rollup merge of rust-lang#57020 - estebank:return-span, r=zackmdavis

    Point to cause of `fn` expected return type
    
    Fix rust-lang#48136.
    Centril committed Dec 23, 2018
    Configuration menu
    Copy the full SHA
    174dfb8 View commit details
    Browse the repository at this point in the history
  14. Rollup merge of rust-lang#57032 - RalfJung:alloc-bench-deprecations, …

    …r=Centril
    
    fix deprecation warnings in liballoc benches
    Centril committed Dec 23, 2018
    Configuration menu
    Copy the full SHA
    ee1c818 View commit details
    Browse the repository at this point in the history
  15. Rollup merge of rust-lang#57053 - nikic:fix-gep-align, r=nagisa

    Fix alignment for array indexing
    
    We need to reduce the alignment with the used offset. If the offset isn't known, use the element size, as this will yield the minimum possible alignment.
    
    This handles both direct array indexing, and array repeat expressions.
    
    Fixes rust-lang#56927.
    
    r? @nagisa
    Centril committed Dec 23, 2018
    Configuration menu
    Copy the full SHA
    841af07 View commit details
    Browse the repository at this point in the history
  16. Rollup merge of rust-lang#57067 - Centril:stabilize-min_const_unsafe_…

    …fn, r=oli-obk
    
    Stabilize min_const_unsafe_fn in 1.33
    
    Fixes rust-lang#55607
    
    r? @oli-obk
    Centril committed Dec 23, 2018
    Configuration menu
    Copy the full SHA
    24a5335 View commit details
    Browse the repository at this point in the history