summary refs log tree commit diff
path: root/compiler/rustc_error_messages
AgeCommit message (Collapse)AuthorLines
2023-01-20Auto merge of #107106 - matthiaskrgr:rollup-g7r1ep0, r=matthiaskrgrbors-1/+2
Rollup of 6 pull requests Successful merges: - #106699 ([drop tracking] Visit break expressions ) - #106738 (Fix known-bug annotations) - #106891 (Tweak "borrow closure argument" suggestion) - #106928 (add raw identifier for keyword in suggestion) - #107065 (Clippy: Make sure to include in beta: Move `unchecked_duration_subtraction` to pedantic) - #107068 (autoderive Subdiagnostic for AddtoExternBlockSuggestion) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2023-01-19Fix broken format strings in `infer.ftl`clubby789-8/+8
2023-01-19Autoderive ExternBlockSuggestionmejrs-1/+2
2023-01-17Rollup merge of #106949 - compiler-errors:is-poly, r=BoxyUwUMatthias Krüger-6/+6
ConstBlocks are poly if their substs are poly r? `@BoxyUwU` fixes #106926
2023-01-17Rollup merge of #106591 - Ezrashaw:attempted-integer-identifer, r=EstebankMatthias Krüger-0/+2
suggestion for attempted integer identifier in patterns Fixes #106552 Implemented a suggestion on `E0005` that occurs when no bindings are present and the pattern is a literal integer.
2023-01-16Properly pluralize 'generic constants'Michael Goulet-6/+6
2023-01-16Improve a TAIT error and add an error code plus documentationOli Scherer-0/+4
2023-01-14suggest fix for attempted integer identifier in patternsEzra Shaw-0/+2
2023-01-13Rollup merge of #106678 - Veykril:proc-macro-panic-abort, r=eholkMatthias Krüger-0/+3
Warn when using panic-strategy abort for proc-macro crates See https://github.com/rust-lang/rust/issues/82320, this simply warns for now as that seems like the best step that can be immediately taken (opposed to straight up rejecting or ignoring)
2023-01-13Auto merge of #106801 - JohnTitor:rollup-xqkraw0, r=JohnTitorbors-0/+3
Rollup of 6 pull requests Successful merges: - #106608 (Render missing generics suggestion verbosely) - #106716 ([RFC 2397] Deny incorrect locations) - #106754 (Rename `Ty::is_ty_infer` -> `Ty::is_ty_or_numeric_infer`) - #106782 (Ignore tests move in git blame) - #106785 (Make blame spans better for impl wfcheck) - #106791 (Fix ICE formatting) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2023-01-13Warn when using panic-strategy abort for proc-macro cratesLukas Wirth-0/+3
2023-01-13Rollup merge of #106716 - c410-f3r:rfc-2397-1, r=davidtwcoYuki Okushi-0/+3
[RFC 2397] Deny incorrect locations cc #51992 As declared in the RFC, `#[do_not_recommend]` should only be applicable on trait implementations.
2023-01-13Auto merge of #106092 - asquared31415:start_lang_item_checks, r=davidtwcobors-0/+11
Add checks for the signature of the `start` lang item Closes #105963
2023-01-13Auto merge of #101138 - Rejyr:diagnostic-migration-rustc-lint-pt2, r=davidtwcobors-2/+59
Migrate `rustc_lint` lint diagnostics Part 2 of [Migrate `rustc_lint` errors to `SessionDiagnostic`](https://github.com/rust-lang/rust/pull/100776) r? `@davidtwco` # TODO - [x] Refactor some lints manually implementing `DecorateLint` to use `Option<Subdiagnostic>`. - [x] Add `#[rustc_lint_diagnostics]` to lint functions in `context.rs`. - [x] Migrate `hidden_unicode_codepoints.rs`. - [x] Migrate `UnsafeCode` in `builtin.rs`. - [x] Migrate the rest of `builtin.rs`.
2023-01-12Rollup merge of #106714 - Ezrashaw:remove-e0490, r=davidtwconils-1/+0
remove unreachable error code `E0490` AFAIK, the untested and undocumented error code `E0490` is now unreachable, it was from the days of the original borrow checker. cc ``@GuillaumeGomez`` #61137
2023-01-12[RFC 2397] Deny incorrect locationsCaio-0/+3
2023-01-11Rollup merge of #106170 - compiler-errors:autoderef-to-analysis, r=lcnrMichael Goulet-4/+4
Move autoderef to `rustc_hir_analysis` Not sure if this is a change we actually want, but autoderef really is only (functionally) used by `rustc_hir_analysis` and `rustc_hir_typeck`, so it probably should live there. Instead, implement a separate autoderef helper in `TypeErrCtxt` for the one use-case that goes against the ordering of the crate graph..
2023-01-11Rollup merge of #106097 - mejrs:mir_build2, r=oli-obkMichael Goulet-0/+61
Migrate mir_build diagnostics 2 of 3 The first three commits are fairly boring, however I've made some changes to the output of the match checking diagnostics.
2023-01-12Auto merge of #106537 - ↵bors-0/+6
fmease:recover-where-clause-before-tuple-struct-body, r=estebank Recover from where clauses placed before tuple struct bodies Open to any suggestions regarding the phrasing of the diagnostic. Fixes #100790. `@rustbot` label A-diagnostics r? diagnostics
2023-01-12remove unreachable error code `E0490`Ezra Shaw-1/+0
2023-01-11Translate `Overlap` eagerlymejrs-2/+0
2023-01-11Don't recommend `if let` if `let else` worksmejrs-1/+1
2023-01-11Migrate pattern matchingmejrs-4/+32
2023-01-11Migrate usefulness.rsmejrs-2/+12
2023-01-11Migrate deconstruct_pat.rsmejrs-1/+7
2023-01-11Translate const_to_pat.rsmejrs-0/+19
2023-01-11add checks for the signature of the lang itemasquared31415-0/+11
2023-01-11Move autoderef to rustc_hir_analysisMichael Goulet-4/+4
2023-01-11Rollup merge of #106622 - estebank:issue-68972, r=davidtwcoMatthias Krüger-0/+4
Detect out of bounds range pattern value Fix #68972.
2023-01-11parser: recover from where clauses placed before tuple struct bodiesLeón Orell Valerian Liehr-0/+6
2023-01-11Detect struct literal needing parenthesesEsteban Küber-0/+4
Fix #82051.
2023-01-11Detect out of bounds range pattern valueEsteban Küber-0/+4
Fix #68972.
2023-01-09migrate: `deref_into_dyn_supertrait.rs`Rejyr-0/+3
2023-01-09migrate: rest of `builtin.rs` without `builtin_asm_labels`Rejyr-2/+10
2023-01-09refactor: refactor to derive for some lints.Rejyr-1/+3
2023-01-09migrate: `for_loops_over_fallibles.rs`Rejyr-0/+7
2023-01-09migrate(wip): `builtin.rs`Rejyr-0/+7
2023-01-09migrate: `internal.rs`Rejyr-0/+2
2023-01-09migrate: `let_underscore.rs`Rejyr-0/+12
fix: NonBindingLetSub
2023-01-09migrate: `levels.rs`Rejyr-0/+12
2023-01-09add: `emit{,_spanned}_lint` for `LintLevelsBuilder`Rejyr-0/+4
add: `emit_spanned_lint` and `emit_lint` for `LintLevelsBuilder` migrate: `DeprecatedLintName`
2023-01-08Mention signature rather than fn pointers when comparing impl/trait methodsMichael Goulet-2/+2
2023-01-07Rollup merge of #104543 - ↵Matthias Krüger-0/+99
JhonnyBillM:migrate-codegen-ssa-to-diagnostics-structs-pt3, r=davidtwco Migrate `codegen_ssa` to diagnostics structs - [Part 3] Completes migrating `codegen_ssa` module except 2 outstanding errors that depend on other crates: 1. [`rustc_middle::mir::interpret::InterpError`](https://github.com/rust-lang/rust/blob/b6097f2e1b2ca62e188ba53cf43bd66b06b36915/compiler/rustc_middle/src/mir/interpret/error.rs#L475): I saw `rustc_middle` is unassigned, I am open to take this work. 2. `codegen_llvm`'s use of `fn span_invalid_monomorphization_error`, which I started to replace in the [last commit](https://github.com/rust-lang/rust/commit/9a31b3cdda78a2c0891828254fe9886e0a1cfd16) of this PR, but would like to know the team's preference on how we should keep replacing the other macros: 2.1. Update macros to expect a `Diagnostic` 2.2. Remove macros and expand the code on each use. See [some examples of the different options in this experimental commit](https://github.com/JhonnyBillM/rust/commit/64aee83e80857dcfa450f0c6e31d5f29c6d577e6) _Part 2 - https://github.com/rust-lang/rust/pull/103792_ r? ``@davidtwco`` Cc ``@compiler-errors``
2023-01-07Rollup merge of #101936 - IntQuant:issue-100717-infer-4, r=compiler-errorsMatthias Krüger-0/+139
Migrating rustc_infer to session diagnostics (part 3) ``@rustbot`` label +A-translation r? rust-lang/diagnostics cc https://github.com/rust-lang/rust/issues/100717 Seems like a part of static_impl_trait.rs emits suggestions in a loop, and note.rs needs to have two instances of the same subdiagnostic, so these will need to wait until we have eager translation/list support. Other than that, there is only error_reporting/mod.rs left to migrate.
2023-01-04Auto merge of #106224 - bjorn3:staticlib_fixes, r=wesleywiserbors-2/+0
Small fixes for --crate-type staticlib The first commit doesn't have an effect until we start translating error messages. The second commit fixes potential linker errors when combining `--crate-type staticlib` with another crate type and I think `-Cprefer-dynamic`.
2023-01-04Rollup merge of #106361 - clubby789:int-literal-too-large, r=estebankMatthias Krüger-0/+1
Note maximum integer literal for `IntLiteralTooLarge` Closes #105908 `@rustbot` label +A-diagnostics
2023-01-03Auto merge of #105609 - bjorn3:shrink_rustc_dev, r=jyn514bors-0/+5
Only include metadata for non-dynamic libraries in rustc-dev The actual object code should be linked from librustc_driver.so, which is still included in rustc-dev. This saves on download time and disk usage. Fixes https://github.com/rust-lang/rust/issues/103538
2023-01-02Print correct base for too-large literalsclubby789-1/+1
Also update tests
2023-01-02Note maximum integer literal for `IntLiteralTooLarge`clubby789-0/+1
2022-12-31Add help for the error message when missing rustc_driverbjorn3-0/+5