Commit Graph

245402 Commits

Author SHA1 Message Date
Nicholas Nethercote
cd4c5cd8b8 Improve a local variable name. 2024-02-03 09:02:50 +11:00
Nicholas Nethercote
6fdaf3ef7f Use DiagnosticArgName in a few more places. 2024-02-03 09:02:50 +11:00
Nicholas Nethercote
df322fc29f Remove some unnecessary clone calls. 2024-02-03 09:02:50 +11:00
Nicholas Nethercote
8ba25d0989 SilentEmitter::fatal_note doesn't need to be optional. 2024-02-03 09:02:50 +11:00
Nicholas Nethercote
a9a2e1565a Diagnostic cleanups
- `emitted_at` isn't used outside the crate.
- `code` and `messages` are public fields, so there's no point have
  trivial getters/setters for them.
- `suggestions` is public, so the comment about "functionality on
  `Diagnostic`" isn't needed.
2024-02-03 09:02:50 +11:00
Nicholas Nethercote
585367f15f Remove an out-of-date comment.
`DiagnosticBuilderInner` was removed some time ago.
2024-02-03 09:02:50 +11:00
Nicholas Nethercote
54c4f94896 Make some fatal errors more concise. 2024-02-03 09:02:50 +11:00
Lukas Markeffsky
30e7b87e26 miri: normalize struct tail in ABI compat check 2024-02-02 21:39:00 +01:00
Ralf Jung
61d1ebe50b
fix typo
Co-authored-by: teor <teor@riseup.net>
2024-02-02 20:12:37 +01:00
Michael Goulet
e951bcff96 Normalize the whole PolyTypeOutlivesPredicate, more simplifications 2024-02-02 18:31:35 +00:00
Michael Goulet
a371059933 Don't hang when there's an infinite loop of outlives obligations 2024-02-02 18:30:21 +00:00
Michael Goulet
7d1fda7b40 Normalize type outlives obligations in NLL 2024-02-02 18:30:21 +00:00
Michael Goulet
7576b77e50 Do process_registered_region_obligations in a loop 2024-02-02 18:30:21 +00:00
Michael Goulet
0e16885abd Use deeply_normalize_with_skipped_universes in when processing type outlives 2024-02-02 18:30:21 +00:00
bors
8f6a72871e Auto merge of #16469 - Young-Flash:ci_typos, r=lnicola
internal: add typos check CI (part 2)

follow up https://github.com/rust-lang/rust-analyzer/pull/16448
2024-02-02 12:02:48 +00:00
Young-Flash
a52a4d9ba4 internal: update typo-check CI setting 2024-02-02 18:32:20 +08:00
Young-Flash
70d6141859 internal: update .typos.tmol 2024-02-02 18:23:11 +08:00
Young-Flash
ba2910a3a7 minor: correct some typos 2024-02-02 18:22:54 +08:00
bors
980d348111 Auto merge of #16476 - lnicola:sync-from-rust, r=lnicola
internal: sync from downstream
2024-02-02 07:07:05 +00:00
Laurențiu Nicola
7a0b887665 Bump rustc_index and rustc_abi 2024-02-02 09:00:21 +02:00
Laurențiu Nicola
ef07b05c0f Bump rustc_lexer and rustc_parse_format 2024-02-02 08:58:34 +02:00
Laurențiu Nicola
4f09335063 Merge remote-tracking branch 'upstream/master' into sync-from-rust 2024-02-02 08:40:28 +02:00
Laurențiu Nicola
8ba31cc4b9 Merge remote-tracking branch 'upstream/release' into sync-from-rust 2024-02-02 08:40:18 +02:00
Nicholas Nethercote
b6a4f03306 Rename BorrowckErrors as BorrowckDiags.
And some related things. Because it can hold non-error diagnostics.
2024-02-02 14:35:51 +11:00
Nicholas Nethercote
2e6bea5968 Inline and remove DiagnosticBuilder::into_diagnostic.
It now has a single call site.
2024-02-02 14:35:51 +11:00
Nicholas Nethercote
5fd824de44 Remove BorrowckErrors::tainted_by_errors.
`BorrowckErrors` stores a mix of error and non-error diags in
`buffered`. As a result, it downgrades `DiagnosticBuilder`s to
`Diagnostic`s, losing the emission guarantees, and so has to use a
`tainted_by_errors` field to record whether an error has occurred.

This commit splits `buffered` into `buffered_errors` and
`buffered_non_errors`, keeping them as `DiagnosticBuilder`s and
preserving the emission guarantees.

This also requires fixing a bunch of incorrect lifetimes on
`DiagnosticBuilder` use points.
2024-02-02 14:35:46 +11:00
Aphek
ee8703315e Update libc to 0.2.153 2024-02-01 23:58:42 -03:00
Nicholas Nethercote
3a02ebcac2 Remove BorrowckErrors::set_tainted_by_errors.
It has no effect. Note that `infcx.set_tainted_by_errors()` is still
called, so taintedness is still being propagated.
2024-02-02 13:27:57 +11:00
Nicholas Nethercote
f066be5f29 Rename buffer_non_error_diag as buffer_non_error.
To match `buffer_error`.
2024-02-02 13:27:57 +11:00
León Orell Valerian Liehr
5906237b32
Suggest changing ty to const params if appropriate 2024-02-02 03:25:04 +01:00
León Orell Valerian Liehr
3f7b1a5f49
Clean up some things in the name resolver
* Get rid of a typo in a function name
* Rename `currently_processing_generics`: The old name confused me at first since
  I assumed it referred to generic *parameters* when it was in fact referring to
  generic *arguments*. Generics are typically short for generic params.
* Get rid of a few unwraps by properly leveraging slice patterns
2024-02-02 02:51:48 +01:00
Tyler Mandry
48f664b502 Ignore test-panic-abort tests on Android
Until #120567 is fixed.
2024-02-01 16:51:07 -08:00
Zalathar
c9c049b2b4 coverage: Use normal edition: headers in coverage tests
Some of these tests were originally written as part of a custom `run-make`
test, so at that time they weren't able to use the normal compiletest header
directive parser.

Now that they're properly integrated, there's no need for them to use
`compile-flags` to specify the edition, since they can use `edition` instead.
2024-02-02 11:17:05 +11:00
Zalathar
2e212b79e0 coverage: Split out counter increment sites from BCB node/edge counters
This makes it possible for two nodes/edges in the coverage graph to share the
same counter, without causing the instrumentor to inject unwanted duplicate
counter-increment statements.
2024-02-02 10:50:05 +11:00
Oli Scherer
6ac035df44 Revert unsound libcore changes of #119911 2024-02-01 22:53:25 +00:00
Esteban Küber
0df6dfdc78 fix rebase 2024-02-01 22:38:16 +00:00
bors
bf3c6c5bed Auto merge of #120447 - lnicola:sync-from-ra, r=lnicola
Subtree update of `rust-analyzer`

r? ghost
2024-02-01 22:17:11 +00:00
Guillaume Gomez
0f21e45e95 Update never_type feature gate ui test 2024-02-01 20:01:05 +01:00
Guillaume Gomez
2c0030ff2c Correctly check never_type feature gating 2024-02-01 20:01:04 +01:00
Jeremiah Senkpiel
bedd81ef2a add test for try-block-in-match-arm
This is noted as an implementation concern under the tracking issue for `?` and `try` blocks. (Issue 31436)
2024-02-01 10:36:34 -08:00
León Orell Valerian Liehr
02320b502d
Improve the diagnostics for unused generic parameters 2024-02-01 16:18:03 +01:00
Felix S. Klock II
0148da3528 put pnkfelix (me) back on the review queue. 2024-02-01 09:51:29 -05:00
bors
850ba2fb63 Auto merge of #16451 - Urhengulas:satisfy-clippy, r=Veykril
internal: Work through temporarily allowed clippy lints, part 2

Another follow-up to https://github.com/rust-lang/rust-analyzer/pull/16401.
2024-02-01 14:23:18 +00:00
Young-Flash
b0be2967cc internal: add typos CI check 2024-02-01 21:07:50 +08:00
Young-Flash
36cb518791 internal: add typos.toml as typo white list 2024-02-01 21:04:38 +08:00
bors
135a8d9841 Auto merge of #16416 - Young-Flash:cargo_ext_detect, r=lnicola
internal: VS Code: report conflict with `panicbit.cargo`

<img width="359" alt="notification" src="https://github.com/rust-lang/rust-analyzer/assets/71162630/420b9f34-ba73-4436-b868-6cd87c62287d">

related to https://github.com/rust-lang/rust-analyzer/issues/16392
2024-02-01 13:00:05 +00:00
Matthew Jasper
4feec41e05 #![feature(inline_const_pat)] is no longer incomplete 2024-02-01 10:27:54 +00:00
bors
3afa6b13c2 Auto merge of #16468 - ThomasFrans:docs-update-plugin-url, r=lnicola
minor: Recommend maintained Neovim plugin in documentation
2024-02-01 10:19:51 +00:00
Thomas Frans
671c776d59
minor: Recommend maintained Neovim plugin in documentation 2024-02-01 11:06:34 +01:00
Nicholas Nethercote
2621f7fd9b Rework StringPart.
When there are two possibilities, both of which use a `String`, it's
nicer to use a struct than an enum. Especially when mapping the contents
into a tuple.
2024-02-01 19:23:01 +11:00