about summary refs log tree commit diff
path: root/src/test/ui/for
AgeCommit message (Collapse)AuthorLines
2023-01-11Move /src/test to /testsAlbert Larsan-131/+0
2022-08-18Reword "Required because of the requirements on the impl of ..."Andy Wang-3/+3
2022-06-02add new `emit_inference_failure_err`lcnr-4/+7
2021-11-21Simplify for loop desugarCameron Steffen-2/+4
2021-11-20Do not mention associated items when they introduce an obligationEsteban Kuber-12/+0
2021-07-19Various diagnostics clean ups/tweaksEsteban Küber-2/+10
* Always point at macros, including derive macros * Point at non-local items that introduce a trait requirement * On private associated item, point at definition
2020-10-06Fix tests from rebaseMatthew Jasper-3/+5
2020-10-06Fix tests and bootstrapMatthew Jasper-9/+11
2020-09-02pretty: trim paths of unique symbolsDan Aloni-6/+6
If a symbol name can only be imported from one place for a type, and as long as it was not glob-imported anywhere in the current crate, we can trim its printed path and print only the name. This has wide implications on error messages with types, for example, shortening `std::vec::Vec` to just `Vec`, as long as there is no other `Vec` importable anywhere. This adds a new '-Z trim-diagnostic-paths=false' option to control this feature. On the good path, with no diagnosis printed, we should try to avoid issuing this query, so we need to prevent trimmed_def_paths query on several cases. This change also relies on a previous commit that differentiates between `Debug` and `Display` on various rustc types, where the latter is trimmed and presented to the user and the former is not.
2020-06-26Show the values and computation that would overflow a const evaluation or ↵Oliver Scherer-2/+2
propagation
2020-06-13Prefer the associated consts for pattern matching errorLzu Tao-2/+2
2020-03-27non-exhastive diagnostic: add note re. scrutinee typeMazdak Farrokhzad-0/+2
2020-02-17Do not emit note suggesting to implement trait to foreign typeLeSeulArtichaut-2/+0
Update tests Extend to other operations Refractor check in a separate function Fix more tests
2019-12-12Update testsLeSeulArtichaut-1/+1
2019-12-12Update UI test expectationsLeSeulArtichaut-1/+1
2019-09-19When possible point at argument causing item obligation failureEsteban Küber-0/+3
2019-09-15use println!()Guanqun Lu-1/+1
2019-09-09check_match: unify check_irrefutable & check_exhaustive more.Mazdak Farrokhzad-2/+2
2019-08-13Suggest giving return type to closures on E0282Esteban Küber-4/+1
2019-08-06pretty-pretty extremal constants!Zack M. Davis-2/+2
While many programmers may intuitively appreciate the significance of "magic numbers" like −2147483648, Rust is about empowering everyone to build reliable and efficient software! It's a bit more legible to print the constant names (even noisy fully-qualified-paths thereof). The bit-manipulation methods mirror those in `librustc_mir::hair::pattern::_match::all_constructors`; thanks to the immortal Varkor for guidance. Resolves #56393.
2019-03-27Better diagnostic for binary operation on BoxedValueshgallagher1993-2/+4
2019-03-11Update testsVadim Petrochenkov-4/+4
2018-12-25Remove licensesMark Rousskov-66/+6
2018-11-30Update existing tests with more precise error messagesvarkor-2/+2
2018-10-09Reword `rustc_on_unimplemented` errors for `Iterator`Esteban Küber-6/+7
- Detect one element array of `Range` type, which is potentially a typo: `for _ in [0..10] {}` where iterating between `0` and `10` was intended. (#23141) - Suggest `.bytes()` and `.chars()` for `String`. - Suggest borrowing or `.iter()` on arrays (#36391) - Suggest using range literal when iterating on integers (#34353) - Do not suggest `.iter()` by default (#50773, #46806)
2018-08-14Merged migrated compile-fail tests and ui tests. Fixes #46841.David Wood-0/+183