about summary refs log tree commit diff
path: root/src/test/ui/issues
AgeCommit message (Collapse)AuthorLines
2021-02-05Add test for #75158Ömer Sinan Ağacan-0/+20
Closes #75158
2021-02-04typeck: Emit structured suggestions for tuple struct syntaxCamelid-2/+2
And tuple variant syntax, but that didn't fit in the subject :) Now the fact that these are suggestions is exposed both to the layout engine and to IDEs and rustfix for automatic application.
2021-02-03Miscellaneous small diagnostics cleanupCamelid-2/+2
2021-02-02Rollup merge of #81634 - jesusprubio:jesusprubio/add-long-explanation-e0521, ↵Jack Huey-0/+2
r=GuillaumeGomez Add long explanation e0521 Helps with #61137
2021-02-02Update ui tests (nll)Jesus Rubio-0/+2
2021-02-02Rollup merge of #81481 - lcnr:cast-tests, r=jackh726Jonas Schievink-17/+0
move some tests
2021-01-31Move some tests to more reasonable directoriesCaio-1355/+0
2021-01-28Auto merge of #81055 - matthewjasper:non-fatal-overflow, r=nikomatsakisbors-1/+2
Make hitting the recursion limit in projection non-fatal This change was originally made in #80246 to avoid future (effectively) infinite loop bugs in projections, but wundergraph relies on rustc recovering here. cc #80953 r? `@nikomatsakis`
2021-01-28move a bunch of testsBastian Kauschke-17/+0
2021-01-28Auto merge of #81149 - Aaron1011:feature/better-no-method-found-err, r=estebankbors-35/+35
Avoid describing a method as 'not found' when bounds are unsatisfied Fixes #76267 When there is a single applicable method candidate, but its trait bounds are not satisfied, we avoid saying that the method is "not found". Insted, we update the error message to directly mention which bounds are not satisfied, rather than mentioning them in a note.
2021-01-26Avoid describing a method as 'not found' when bounds are unsatisfiedAaron Hill-35/+35
Fixes #76267 When there is a single applicable method candidate, but its trait bounds are not satisfied, we avoid saying that the method is "not found". Insted, we update the error message to directly mention which bounds are not satisfied, rather than mentioning them in a note.
2021-01-26Point only at generic arguments when they are unexpectedEsteban Küber-2/+2
2021-01-23Move SIMD testsCaleb Zulawski-60/+0
2021-01-23Fix maximum SIMD lane count, and expose it to other crates. Disallow SIMD ↵Caleb Zulawski-2/+29
vectors with non-power-of-two lengths.
2021-01-23Adjust wording of a diagnosticoli-1/+1
2021-01-23Permit mutable references in all const contextsoli-3/+3
2021-01-23Auto merge of #80065 - b-naber:parse-angle-arg-diagnostics, r=petrochenkovbors-6/+9
Improve diagnostics when parsing angle args https://github.com/rust-lang/rust/pull/79266 introduced parsing of generic arguments in associated type constraints, this however resulted in possibly very confusing error messages in cases in which closing angle brackets were missing such as in `Vec<(u32, _, _) = vec![]`, which outputs an incorrectly parsed equality constraint error, as noted by `@cynecx.` This PR tries to provide better error messages in such cases. r? `@petrochenkov`
2021-01-22add and update testsb-naber-6/+9
2021-01-21Account for labels when suggesting `loop` instead of `while true`Esteban Küber-7/+7
2021-01-16Move some tests to more reasonable directories - 2Caio-4166/+0
Address comments Update limits
2021-01-15Make hitting the recursion limit in projection non-fatalMatthew Jasper-1/+2
This is relied on by wundergraph.
2021-01-14Rollup merge of #80017 - camelid:sugg-rest-pattern, r=estebankMara Bos-0/+14
Suggest `_` and `..` if a pattern has too few fields Fixes #80010.
2021-01-14Auto merge of #79328 - c410-f3r:hir-if, r=matthewjasperbors-0/+2
Reintroduce hir::ExprKind::If Basically copied and paste #59288/https://github.com/rust-lang/rust-clippy/pull/4080 with some modifications. The vast majority of tests were fixed and now there are only a few remaining. Since I am still unable to figure out the missing pieces, any help with the following list is welcome. - [ ] **Unnecessary `typeck` exception**: [Cheated on this one to make CI green.](https://github.com/rust-lang/rust/pull/79328/files#diff-3faee9ba23fc54a12b7c43364ba81f8c5660045c7e1d7989a02a0cee1c5b2051) - [x] **Incorrect span**: [Span should reference `then` and `else` separately.](https://github.com/rust-lang/rust/pull/79328/files#diff-cf2c46e82222ee4b1037a68fff8a1af3c4f1de7a6b3fd798aacbf3c0475abe3d) - [x] **New note regarding `assert!`**: [Modified but not "wrong". Maybe can be a good thing?](https://github.com/rust-lang/rust/pull/79328/files#diff-9e0d7c89ed0224e2b62060c957177c27db43c30dfe3c2974cb6b5091cda9cfb5) - [x] **Inverted report location**: [Modified but not "wrong". Locations were inverted.](https://github.com/rust-lang/rust/pull/79328/files#diff-f637ce7c1f68d523a165aa9651765df05e36c4d7d279194b1a6b28b48a323691) - [x] **`src/test/ui/point-to-type-err-cause-on-impl-trait-return.rs` has weird errors**: [Not sure why this is happening.](https://github.com/rust-lang/rust/pull/79328/files#diff-c823c09660f5b112f95e97e8ff71f1797b6c7f37dbb3d16f8e98bbaea8072e95) - [x] **Missing diagnostic**: [???](https://github.com/rust-lang/rust/pull/79328/files#diff-6b8ab09360d725ba4513933827f9796b42ff9522b0690f80b76de067143af2fc)
2021-01-13Auto merge of #77524 - Patryk27:fixes/66228, r=estebankbors-28/+102
Rework diagnostics for wrong number of generic args (fixes #66228 and #71924) This PR reworks the `wrong number of {} arguments` message, so that it provides more details and contextual hints.
2021-01-13Update code to account for extern ABI requirementMark Rousskov-10/+10
2021-01-13Update tests for extern block lintingMark Rousskov-84/+79
2021-01-12Include `..` suggestion if fields are all wildcardsCamelid-0/+4
2021-01-12Always show suggestions in their own subwindowsCamelid-8/+12
2021-01-12Only suggest `..` if more than one field is missingCamelid-20/+8
2021-01-12Specialize `..` help message for all fields vs. the restCamelid-2/+2
2021-01-12Suggest `_` and `..` if a pattern has too few fieldsCamelid-0/+18
For example, this code: struct S(i32, f32); let S(x) = S(0, 1.0); will make the compiler suggest either: let S(x, _) = S(0, 1.0); or: let S(x, ..) = S(0, 1.0);
2021-01-12Provide more information for HRTB lifetime errors involving closuresEsteban Küber-2/+5
2021-01-12Rollup merge of #80930 - euclio:trait-method-mutability-help, r=estebankYuki Okushi-5/+4
fix typo in trait method mutability mismatch help
2021-01-12Rollup merge of #80880 - c410-f3r:tests-tests-tests, r=petrochenkovYuki Okushi-95/+0
Move some tests to more reasonable directories The idea is to move `issues`/`ui` tests in small batches r? `@petrochenkov`
2021-01-11fix typo in trait method mutability mismatch helpAndy Russell-5/+4
2021-01-12Rollup merge of #80324 - Aaron1011:loop-move-fn-self, r=oli-obkYuki Okushi-3/+3
Explain method-call move errors in loops PR #73708 added a more detailed explanation of move errors that occur due to a call to a method that takes `self`. This PR extends that logic to work when a move error occurs due to a method call in the previous iteration of a loop.
2021-01-11Move some tests to more reasonable directoriesCaio-95/+0
2021-01-10Rework diagnostics for wrong number of generic argsPatryk Wychowaniec-28/+102
2021-01-08Change wording of noteAaron Hill-3/+3
2021-01-07Use correct span for structured suggestionEsteban Küber-25/+82
On structured suggestion for `let` -> `const` and `const` -> `let`, use a proper `Span` and update tests to check the correct application. Follow up to #80012.
2021-01-07Reintroduce hir::ExprKind::IfCaio-0/+2
2021-01-07bless testsDaiki Ihara-4/+22
2021-01-04Auto merge of #80418 - oli-obk:this_could_have_been_so_simple, r=RalfJungbors-9/+9
Allow references to interior mutable data behind a feature gate supercedes #80373 by simply not checking for interior mutability on borrows of locals that have `StorageDead` and thus can never be leaked to the final value of the constant tracking issue: https://github.com/rust-lang/rust/issues/80384 r? `@RalfJung`
2021-01-03Refactor the non-transient cell borrow error diagnosticoli-9/+9
2021-01-03Update now-more-precise operation with a preciser messageoli-6/+6
2021-01-02Print actual enum variantDániel Buga-3/+3
2021-01-02Add test for #80607 with undesired outputDániel Buga-0/+24
2021-01-01Reinstate the error-code error over the feature gate erroroli-5/+3
2021-01-01Allow references to interior mutable data behind a feature gateoli-6/+8
2020-12-31Rollup merge of #80519 - max-heller:issue-80512-fix, r=varkorDylan DPC-0/+12
Take type defaults into account in suggestions to reorder generic parameters Fixes #80512