about summary refs log tree commit diff
AgeCommit message (Collapse)AuthorLines
2023-11-25rustc: Make `def_kind` mandatory for all `DefId`sVadim Petrochenkov-3/+2
2023-11-25rustc: Make `def_kind` mandatory for all `DefId`sVadim Petrochenkov-56/+36
2023-11-25Auto merge of #11864 - GuillaumeGomez:option_map_or_err_ok, r=flip1995bors-1/+106
Create new lint `option_map_or_err_ok` Fixes #10045. For the following code: ```rust let opt = Some(1); opt.map_or(Err("error"), Ok); ``` It suggests to instead write: ```rust let opt = Some(1); opt.ok_or("error"); ``` r? `@flip1995` changelog: Create new lint `option_map_or_err_ok`
2023-11-25fix: add fallback for completion label detailsAndrew Hlynskyi-1/+3
2023-11-25Auto merge of #11866 - GuillaumeGomez:simplify-code-result_map_or_else_none, ↵bors-9/+5
r=flip1995 Simplify code for `result_map_or_else_none` As mentioned in https://github.com/rust-lang/rust-clippy/pull/11864. r? `@flip1995` changelog: Simplify code for `result_map_or_else_none`
2023-11-25Auto merge of #118277 - fmease:rollup-itucldm, r=fmeasebors-2360/+2512
Rollup of 9 pull requests Successful merges: - #118220 (general improvements/fixes on bootstrap) - #118251 (rustdoc-search: avoid infinite where clause unbox) - #118253 (Replace `option.map(cond) == Some(true)` with `option.is_some_and(cond)`) - #118255 (Request that rust-analyzer changes are sent upstream first if possible) - #118259 (Move EagerResolution to rustc_infer::infer::resolve) - #118262 (Relate Inherent Associated Types using eq) - #118266 (Move stuff around on `stable_mir` and `rustc_smir` crate) - #118271 (Separate `NaN`/`Inf` floats with `_`) - #118274 (Fix smir's `Ty::Ref` pretty printing) r? `@ghost` `@rustbot` modify labels: rollup
2023-11-25Auto merge of #3190 - RalfJung:freebsd32, r=RalfJungbors-5/+6
test Miri on 32bit FreeBSD
2023-11-25Merge branch 'sync_from_rust'bjorn3-0/+0
2023-11-25Simplify code for `result_map_or_else_none`Guillaume Gomez-9/+5
2023-11-25Merge commit '710c67909d034e1c663174a016ca82b95c2d6c12' into ↵bjorn3-71/+452
sync_cg_clif-2023-11-25
2023-11-25Merge commit '710c67909d034e1c663174a016ca82b95c2d6c12' into ↵bjorn3-71/+452
sync_cg_clif-2023-11-25
2023-11-25Merge pull request #1431 from rust-lang/even_more_simd_intrinsicsbjorn3-21/+347
Implement another batch of vendor intrinsics
2023-11-25Re-enable rustc test that was disabled due to a rustc bugbjorn3-5/+0
2023-11-25run tests on 32bit freebsdRalf Jung-0/+1
2023-11-25read off_t at the right size for the current targetRalf Jung-3/+3
2023-11-25Rustup to rustc 1.76.0-nightly (37b2813a7 2023-11-24)bjorn3-1/+1
2023-11-25Sync from rust 37b2813a7be580ef59048a6bd08444c79e5cc97fbjorn3-1/+50
2023-11-25Rollup merge of #118274 - celinval:smir-fix-pretty, r=ouz-aLeón Orell Valerian Liehr-2/+4
Fix smir's `Ty::Ref` pretty printing Add `&` or `&mut` to reference when generating a string for `TyKind::Ref`. r? `@ouz-a`
2023-11-25Rollup merge of #118271 - compiler-errors:float, r=RalfJungLeón Orell Valerian Liehr-2/+5
Separate `NaN`/`Inf` floats with `_` r? RalfJung Fixes #118221 No test 🤷 unless you know a good way to print an `ImmTy` in a unit test?
2023-11-25Rollup merge of #118266 - celinval:smir-break-files, r=compiler-errorsLeón Orell Valerian Liehr-2150/+2205
Move stuff around on `stable_mir` and `rustc_smir` crate 1. Break down rustc_smir/mod.rs file. - This file was getting too big and causing a lot of merge conflicts. All these changes shouldn't be visible to users since this module is private. 2. Move the compiler interface defs to its own module - Separate items that are exposed in the `stable_mir` crate to be used by the compiler from items that we expect to be used by tool developers.
2023-11-25Rollup merge of #118262 - spastorino:relate-iats-using-eq, r=compiler-errorsLeón Orell Valerian Liehr-4/+1
Relate Inherent Associated Types using eq We should call `eq` instead of `sup` as we're relating `Ty` directly and not `Binder<TraitRef>`. This is part of #118118 but unrelated to that PR. r? `@compiler-errors` `@lcnr`
2023-11-25Rollup merge of #118259 - spastorino:move-eager-resolver-to-infer, ↵León Orell Valerian Liehr-80/+87
r=compiler-errors Move EagerResolution to rustc_infer::infer::resolve `EagerResolver` fits better in `rustc_infer::infer::resolver`. Started to disentagle #118118 that has a lot of unrelated things. r? `@compiler-errors` `@lcnr`
2023-11-25Rollup merge of #118255 - dtolnay:mentionsrustanalyzer, r=Mark-SimulacrumLeón Orell Valerian Liehr-0/+6
Request that rust-analyzer changes are sent upstream first if possible This automates `@lnicola's` comment https://github.com/rust-lang/rust/pull/118253#issuecomment-1825925242. Rustbot will write a comment similar to https://github.com/rust-lang/rust/pull/116743#issuecomment-1763178813.
2023-11-25Rollup merge of #118253 - dtolnay:issomeand, r=compiler-errorsLeón Orell Valerian Liehr-22/+21
Replace `option.map(cond) == Some(true)` with `option.is_some_and(cond)` Requested by `@fmease` in https://github.com/rust-lang/rust/pull/118226#pullrequestreview-1747432292. There is also a much larger number of `option.map_or(false, cond)` that can be changed separately if someone wants. r? fmease
2023-11-25Rollup merge of #118251 - notriddle:notriddle/less-recursion, r=GuillaumeGomezLeón Orell Valerian Liehr-8/+68
rustdoc-search: avoid infinite where clause unbox Fixes #118242
2023-11-25Rollup merge of #118220 - onur-ozkan:followups, r=Mark-SimulacrumLeón Orell Valerian Liehr-92/+115
general improvements/fixes on bootstrap - adds #117813 into change tracker https://github.com/rust-lang/rust/pull/118220/commits/6d9b92f83fc024d4e86fc90436860903829289bb - fixes a bug in change tracker https://github.com/rust-lang/rust/pull/118220/commits/63a44109525d7ead76390cf50024939b2118b5ba - relocates `CONFIG_CHANGE_HISTORY` https://github.com/rust-lang/rust/pull/118220/commits/a7dcb984f644eaa56d91028abcc6e71c2cc2511b
2023-11-25make tests/utils work with edition 2015Ralf Jung-2/+2
2023-11-25Fix incorrect implementation of several vendor intrinsicsbjorn3-16/+16
2023-11-25Auto merge of #118075 - tmiasko:validate-critical-call-edges, r=cjgillotbors-2/+56
Validate there are no critical call edges in optimized MIR
2023-11-25Auto merge of #3187 - RalfJung:rustup, r=RalfJungbors-6351/+7654
Rustup
2023-11-25blessRalf Jung-2/+2
2023-11-25Auto merge of #118203 - nnethercote:rustc_mir_dataflow, r=cjgillotbors-227/+132
Minor `rustc_mir_dataflow` cleanups r? `@cjgillot`
2023-11-25fmtRalf Jung-4/+1
2023-11-25Merge from rustcRalf Jung-6349/+7655
2023-11-25Preparing for merge from rustcRalf Jung-1/+1
2023-11-25Auto merge of #118261 - spastorino:fix-placeholder-replacer, r=compiler-errorsbors-4/+18
Make PlaceholderReplacer shallow_resolver and recur when infer vars This makes resolve type and const infer vars resolve. Given: ```rust #![feature(inherent_associated_types)] #![allow(incomplete_features)] struct Foo<T>(T); impl<'a> Foo<fn(&'a ())> { type Assoc = &'a (); } fn bar(_: for<'a> fn(Foo<fn(Foo<fn(&'static ())>::Assoc)>::Assoc)) {} fn main() {} ``` We should normalize `for<'a> fn(Foo<fn(Foo<fn(&'static ())>::Assoc)>::Assoc)` to `for<'0> fn(&'1 ())` with `'1 == '0` and `'0 == 'static` constraints. We have to resolve `'1` to `'static` in the infcx associated to `PlaceholderReplacer`. This is part of https://github.com/rust-lang/rust/pull/118118 but unrelated to that PR. r? `@compiler-errors` `@lcnr`
2023-11-24Update cargoWeihang Lo-40/+0
This removes the check to ensure that `rustfix` between * src/tools/cargo * src/tools/compiletest has the same version, since `rust-lang/rustfix` has migrated to under `rust-lang/cargo`.
2023-11-24Fix smir's `Ty::Ref` pretty printingCelina G. Val-2/+4
2023-11-25Auto merge of #118227 - Mark-Simulacrum:worker-local-outline, r=cjgillotbors-9/+12
Optimize QueryArena allocation This shifts the WorkerLocal wrapper to be outside the QueryArena, meaning that instead of having each query allocate distinct arenas per-worker we allocate the full set of arenas per-worker. This is primarily a code size optimization (locally, ~85 kilobytes, [perf is reporting >100 kilobytes](https://perf.rust-lang.org/compare.html?start=1fd418f92ed13db88a21865ba5d909abcf16b6cc&end=884c95a3f1fe8d28630ec3cdb0c8f95b2e539fde&stat=instructions%3Au&tab=artifact-size)), saving a bunch of code in the initialization of the arenas which was previously duplicated lots of times (per arena type). Additionally this tells LLVM that the thread count can't be zero in this code (I believe this is true?) which shaves some small amount of bytes off as well since we eliminate checks for zero in the vec allocations.
2023-11-25coverage: Assert that bcb0 starts with bb0 and has no in-edgesZalathar-0/+13
This explains why we don't have to worry about bcb0 having multiple in-edges.
2023-11-25coverage: Eliminate `BcbBranch`Zalathar-104/+69
`BcbBranch` represented an out-edge of a coverage graph node, but would silently refer to a node instead in cases where that node only had one in-edge. Instead we now refer to a graph edge as a `(from_bcb, to_bcb)` pair, or sometimes as just one of those nodes when the other node is implied by the surrounding context. The case of sole in-edges is handled by special code added directly to `get_or_make_edge_counter_operand`.
2023-11-25coverage: Extract `CoverageGraph::bcb_has_multiple_in_edges`Zalathar-9/+16
This was previously a helper method in `MakeBcbCounters`, but putting it in the graph lets us call it from `BcbBranch`, and gives us a more fine-grained borrow.
2023-11-25coverage: Simplify building coverage expressions based on sumsZalathar-171/+154
In some cases we need to prepare a coverage expression that is the sum of an arbitrary number of other terms. This patch simplifies the code paths that build those sums. This causes some churn in the mappings, because the previous code was building its sums in a somewhat idiosyncratic order.
2023-11-25coverage: Use `BcbCounter` to build coverage expressionsZalathar-19/+16
This means that we no longer have to manage the distinction between `BcbCounter` and `CovTerm` when preparing expressions.
2023-11-25coverage: Push down creation of a visited node's counterZalathar-6/+7
Now that this code path unconditionally calls `make_branch_counters`, we might as well make that method responsible for creating the node's counter as well, since it needs the resulting term anyway.
2023-11-25coverage: Push down and inline `bcb_needs_branch_counters`Zalathar-9/+10
This lets us avoid creating two copies of the node's branch list.
2023-11-25coverage: Rename parameter `branching_bcb` to `from_bcb`Zalathar-9/+7
2023-11-25Add more benchmarks of `Vec::dedup`AngelicosPhosphoros-18/+105
They are for more specific cases than old benches. Also, better usage of blackbox
2023-11-25Auto merge of #118235 - psumbera:bootstrap-main-t, r=Mark-Simulacrumbors-3/+3
Fix build on Solaris after #117815.
2023-11-24Separate Nan/Inf floats with _Michael Goulet-2/+5