-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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 9 pull requests #106193
Rollup of 9 pull requests #106193
Conversation
The signature for new was ``` fn new<F>(f: F) -> Lazy<T, F> ``` Notably, with `F` unconstrained, `T` can be literally anything, and just `let _ = Lazy::new(|| 92)` would not typecheck. This historiacally was a necessity -- `new` is a `const` function, it couldn't have any bounds. Today though, we can move `new` under the `F: FnOnce() -> T` bound, which gives the compiler enough data to infer the type of T from closure.
Show the suggestion if and only if the bounds are from the same source context.
This can actually make a difference for the user if they rely on unicode formating. Prompted by dtolnay/syn#771
…extend(array.iter().copied())`
This fixes the spelling of "deallocated" (instead of the original "deallocted") In the `cell.rs` source file
More inference-friendly API for lazy The signature for new was ``` fn new<F>(f: F) -> Lazy<T, F> ``` Notably, with `F` unconstrained, `T` can be literally anything, and just `let _ = Lazy::new(|| 92)` would not typecheck. This historiacally was a necessity -- `new` is a `const` function, it couldn't have any bounds. Today though, we can move `new` under the `F: FnOnce() -> T` bound, which gives the compiler enough data to infer the type of T from closure.
…rors Detect likely `.` -> `..` typo in method calls Fix rust-lang#65015.
…jgillot Suggest rewriting a malformed hex literal if we expect a float Fixes rust-lang#104706
…gillot Provide local extern function arg names Fixes rust-lang#105896
Partially fix `explicit_outlives_requirements` lint in macros Show the suggestion if and only if the bounds are from the same source context. fixes rust-lang#106044 fixes rust-lang#106063
…rors Fix a formatting error in Iterator::for_each docs There is a formatting error (extra space in an assignment) in the documentation of `core::iter::Iterator::for_each`, which I have fixed in this pull request.
Fix doc comment parsing description in book This can actually make a difference for the user if they rely on unicode formating. Prompted by dtolnay/syn#771
…r-errors Update the documentation of `Vec` to use `extend(array)` instead of `extend(array.iter().copied())` Another option is to use `extend_from_slice()` (that may be faster), but I find this approach cleaner.
Fix UnsafeCell Documentation Spelling Error This fixes the spelling of "deallocated" (instead of the original "deallocted") In the `cell.rs` source file. Honestly probably not worth the time to evaluate, but since it doesn't involve any code change, I figure why not?
@bors r+ rollup=never p=9 |
☀️ Test successful - checks-actions |
📌 Perf builds for each rolled up PR: previous master: 92c1937a90 In the case of a perf regression, run the following command for each PR you suspect might be the cause: |
Finished benchmarking commit (739d68a): comparison URL. Overall result: no relevant changes - no action needed@rustbot label: -perf-regression Instruction countThis benchmark run did not return any relevant results for this metric. Max RSS (memory usage)ResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
|
Successful merges:
.
->..
typo in method calls #105765 (Detect likely.
->..
typo in method calls)explicit_outlives_requirements
lint in macros #106064 (Partially fixexplicit_outlives_requirements
lint in macros)Vec
to useextend(array)
instead ofextend(array.iter().copied())
#106187 (Update the documentation ofVec
to useextend(array)
instead ofextend(array.iter().copied())
)Failed merges:
r? @ghost
@rustbot modify labels: rollup
Create a similar rollup