about summary refs log tree commit diff
path: root/src/test/ui/compare-method
AgeCommit message (Collapse)AuthorLines
2019-03-11Update testsVadim Petrochenkov-4/+4
2018-12-25Remove licensesMark Rousskov-93/+14
2018-05-16Remove empty filesJane Lusby-0/+0
2018-03-14update testsGuillaume Gomez-8/+8
2018-02-26Update UI testsVadim Petrochenkov-28/+28
2018-02-25Update ui testsGuillaume Gomez-0/+8
2017-12-18Point at def span in "impl has stricter requirements" diagnosticEsteban Küber-25/+19
2017-11-24Merge cfail and ui tests into ui testsOliver Schneider-3/+3
2017-11-16fix error messages relating to removing lint for E0276Niko Matsakis-10/+2
2017-08-09rustc: Rearchitect lints to be emitted more eagerlyAlex Crichton-2/+2
In preparation for incremental compilation this commit refactors the lint handling infrastructure in the compiler to be more "eager" and overall more incremental-friendly. Many passes of the compiler can emit lints at various points but before this commit all lints were buffered in a table to be emitted at the very end of compilation. This commit changes these lints to be emitted immediately during compilation using pre-calculated lint level-related data structures. Linting today is split into two phases, one set of "early" lints run on the `syntax::ast` and a "late" set of lints run on the HIR. This commit moves the "early" lints to running as late as possible in compilation, just before HIR lowering. This notably means that we're catching resolve-related lints just before HIR lowering. The early linting remains a pass very similar to how it was before, maintaining context of the current lint level as it walks the tree. Post-HIR, however, linting is structured as a method on the `TyCtxt` which transitively executes a query to calculate lint levels. Each request to lint on a `TyCtxt` will query the entire crate's 'lint level data structure' and then go from there about whether the lint should be emitted or not. The query depends on the entire HIR crate but should be very quick to calculate (just a quick walk of the HIR) and the red-green system should notice that the lint level data structure rarely changes, and should hopefully preserve incrementality. Overall this resulted in a pretty big change to the test suite now that lints are emitted much earlier in compilation (on-demand vs only at the end). This in turn necessitated the addition of many `#![allow(warnings)]` directives throughout the compile-fail test suite and a number of updates to the UI test suite.
2017-07-08Make sufficiently old or low-impact compatibility lints deny-by-defaultVadim Petrochenkov-18/+9
2017-07-02Revert "Change error count messages"Ariel Ben-Yehuda-8/+8
This reverts commit 5558c64f33446225739c1153b43d2e309bb4f50e.
2017-05-24Change error count messagesMichael Kohl-8/+8
See #33525 for details.
2017-04-20Reduce visual clutter of multiline start when possibleEsteban Küber-6/+4
When a span starts on a line with nothing but whitespace to the left, and there are no other annotations in that line, simplify the visual representation of the span. Go from: ```rust error[E0072]: recursive type `A` has infinite size --> file2.rs:1:1 | 1 | struct A { | _^ starting here... 2 | | a: A, 3 | | } | |_^ ...ending here: recursive type has infinite size | ``` To: ```rust error[E0072]: recursive type `A` has infinite size --> file2.rs:1:1 | 1 | / struct A { 2 | | a: A, 3 | | } | |_^ recursive type has infinite size ``` Remove `starting here...`/`...ending here` labels from all multiline diagnostics.
2017-02-04note individual lint name set via lint group attribute in notesZack M. Davis-2/+4
Warning or error messages set via a lint group attribute (e.g. `#[deny(warnings)]`) should still make it clear which individual lint (by name) was triggered, similarly to how we include "on by default" language for default lints. This—and, while we're here, the existing "on by default" language—can be tucked into a note rather than cluttering the main error message. This occasions the slightest of refactorings (we now have to get the diagnostic-builder with the main message first, before matching on the lint source). This is in the matter of #36846.
2017-01-20Test fixes from the rollupAlex Crichton-12/+2
2017-01-17Teach Diagnostics to highlight textEsteban Küber-1/+1
2016-11-22Show multiline spans in full if short enoughEsteban Küber-8/+16
When dealing with multiline spans that span few lines, show the complete span instead of restricting to the first character of the first line. For example, instead of: ``` % ./rustc foo.rs error[E0277]: the trait bound `{integer}: std::ops::Add<()>` is not satisfied --> foo.rs:13:9 | 13 | foo(1 + bar(x, | ^ trait `{integer}: std::ops::Add<()>` not satisfied | ``` show ``` % ./rustc foo.rs error[E0277]: the trait bound `{integer}: std::ops::Add<()>` is not satisfied --> foo.rs:13:9 | 13 | foo(1 + bar(x, | ________^ starting here... 14 | | y), | |_____________^ ...ending here: trait `{integer}: std::ops::Add<()>` not satisfied | ```
2016-11-01move compile-fail tests to ui testsNiko Matsakis-7/+313
gets more comprehensive coverage in `ui`
2016-11-01update ref fileNiko Matsakis-8/+0
2016-11-01compare-method lintNiko Matsakis-9/+36
2016-11-01cleanup error reporting and add `ui` testsNiko Matsakis-0/+113