about summary refs log tree commit diff
path: root/src/test/ui/structs
AgeCommit message (Collapse)AuthorLines
2019-04-23Auto merge of #60172 - varkor:tidy-double-trailing-newline, r=kennytmbors-1/+0
Disallow double trailing newlines in tidy This wasn't done previously in https://github.com/rust-lang/rust/pull/47064#issuecomment-354533010 as it affected too many files, but I think it's best to fix it now so that the number of files with double trailing newlines doesn't keep increasing. r? kennytm
2019-04-22review comments: deduplicate testsEsteban Küber-54/+4
2019-04-22Continue evaluating after item-type checkingEsteban Küber-7/+22
2019-04-22Remove double trailing newlinesvarkor-1/+0
2019-04-18hide `--explain` hint if error has no extended infoAndy Russell-5/+5
2019-03-25Auto merge of #59240 - euclio:struct-field-span, r=oli-obkbors-1/+1
use the identifier span for missing struct field
2019-03-20Update testsvarkor-12/+12
2019-03-16use the identifier span for missing struct fieldAndy Russell-1/+1
2019-03-11Update testsVadim Petrochenkov-41/+41
2019-03-02Point at enum definition when match patterns are not exhaustiveEsteban Küber-2/+11
``` error[E0004]: non-exhaustive patterns: type `X` is non-empty --> file.rs:9:11 | 1 | / enum X { 2 | | A, | | - variant not covered 3 | | B, | | - variant not covered 4 | | C, | | - variant not covered 5 | | } | |_- `X` defined here ... 9 | match x { | ^ | = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms error[E0004]: non-exhaustive patterns: `B` and `C` not covered --> file.rs:11:11 | 1 | / enum X { 2 | | A, 3 | | B, 4 | | C, | | - not covered 5 | | } | |_- `X` defined here ... 11 | match x { | ^ patterns `C` not covered ``` When a match expression doesn't have patterns covering every variant, point at the enum's definition span. On a best effort basis, point at the variant(s) that are missing. This does not handle the case when the missing pattern is due to a field's enum variants: ``` enum E1 { A, B, C, } enum E2 { A(E1), B, } fn foo() { match E2::A(E1::A) { E2::A(E1::B) => {} E2::B => {} } //~^ ERROR `E2::A(E1::A)` and `E2::A(E1::C)` not handled } ``` Unify look between match with no arms and match with some missing patterns. Fix #37518.
2019-01-14Rollup merge of #57477 - euclio:clarify-lev-suggestion, r=zackmdavisMazdak Farrokhzad-1/+1
clarify resolve typo suggestion Include the kind of the binding that we're suggesting, and use a structured suggestion. Fixes #53445.
2019-01-12Reword label as per review commentEsteban Küber-3/+3
2019-01-12Point at the match discriminant when arm pattern has a type mismatchEsteban Küber-0/+6
2019-01-09clarify resolve typo suggestionAndy Russell-1/+1
Include the kind of the binding that we're suggesting, and use a structured suggestion.
2019-01-06tests: Do not use `-Z parse-only`, continue compilation to test recoveryVadim Petrochenkov-11/+9
2019-01-02Auto merge of #57250 - codeworm96:tyerr_msg, r=varkorbors-21/+21
Improve type mismatch error messages Closes #56115. Replace "integral variable" with "integer" and replace "floating-point variable" with "floating-point number" to make the message less confusing. TODO the book and clippy needs to be changed accordingly later. r? @varkor
2018-12-31Improve type mismatch error messagesYuning Zhang-21/+21
Replace "integral variable" with "integer" and replace "floating-point variable" with "floating-point number" to make the message less confusing.
2018-12-31Auto merge of #57047 - euclio:field-structured-suggestions, r=estebankbors-6/+7
use structured suggestions for nonexistent fields r? @estebank
2018-12-31use structured suggestions for nonexistent fieldsAndy Russell-6/+7
2018-12-26Added regression test for using generic parameters on modules.Alexander Regueiro-21/+21
2018-12-25Remove licensesMark Rousskov-349/+69
2018-12-24make non_camel_case_types an early lintAndy Russell-10/+10
2018-10-28resolve: More precise spans for privacy errorsVadim Petrochenkov-8/+8
2018-10-11structured suggestion for E0223 ambiguous associated typeZack M. Davis-9/+3
It looks like we tend to use angle-brackets around the placeholder in the few other places we use `Applicability::HasPlaceholders`, but that would be confusing here, so ...
2018-08-24updates tests to use new error codeMatthew Russo-4/+4
2018-08-20Fix diagnostic regressionvarkor-4/+4
2018-08-20Update new ui testsvarkor-2/+2
2018-08-14Merged migrated compile-fail tests and ui tests. Fixes #46841.David Wood-0/+1388