about summary refs log tree commit diff
path: root/src/librustc_errors
AgeCommit message (Collapse)AuthorLines
2019-04-03Deny internal lints on non conflicting cratesflip1995-0/+1
- libarena - librustc_allocator - librustc_borrowck - librustc_codegen_ssa - librustc_codegen_utils - librustc_driver - librustc_errors - librustc_incremental - librustc_metadata - librustc_passes - librustc_privacy - librustc_resolve - librustc_save_analysis - librustc_target - librustc_traits - libsyntax - libsyntax_ext - libsyntax_pos
2019-03-31Rollup merge of #58805 - fabric-and-ink:redundant_import, r=petrochenkovMazdak Farrokhzad-1/+1
Lint for redundant imports Add lint for redundant imports. The changes are suggested by @petrochenkov. Closes #10178.
2019-03-31Rollup merge of #59574 - JohnTitor:distinguish-error-vs-warning, r=CentrilMazdak Farrokhzad-3/+14
Distinguish message for external macros depending on error level fixes #57716 (I picked you because assigned to this issue.) r? @estebank
2019-03-31Distinguish depending on error levelYuki OKUSHI-3/+14
Remove unnecessary comment
2019-03-30Remove redundant importsFabian Drinck-1/+1
2019-03-28Fix MultilineAnnotation field nameEsteban Küber-1/+1
2019-03-28Add comemnts clarifying logicEsteban Küber-0/+5
2019-03-28review commentsEsteban Küber-3/+3
2019-03-27Account for fully overlapping multiline annotationsEsteban Küber-13/+47
When two multiline span labels point at the same span, we special case the output to avoid weird behavior: ``` foo( _____^ |_____| || bar, || ); || ^ ||______| |______foo baz ``` instead showing ``` foo( _____^ | bar, | ); | ^ | | |______foo baz ```
2019-03-23Tweak unsupported negative trait bounds messageEsteban Küber-1/+1
2019-03-12Stabilize Range*::contains.Steven Malis-1/+0
2019-03-07fix bad logicEsteban Küber-3/+4
2019-03-07Keep current behavior while accepting error countEsteban Küber-8/+18
2019-03-06Make `-Z treat-err-as-bug` take a number of errors to be emittedEsteban Küber-10/+19
`-Z treat-err-as-bug=0` will cause `rustc` to panic after the first error is reported. `-Z treat-err-as-bug=2` will cause `rustc` to panic after 3 errors have been reported.
2019-02-24Use ? in some macrosTaiki Endo-3/+3
2019-02-14Rollup merge of #58296 - estebank:hidden-suggestion, r=oli-obkMazdak Farrokhzad-37/+221
Hidden suggestion support Add way to hide suggestion snippet window from cli output to avoid cluttered spans that don't enhance understanding. r? @pietroalbini CC @zackmdavis
2019-02-12Auto merge of #58341 - alexreg:cosmetic-2-doc-comments, r=steveklabnikbors-7/+7
Cosmetic improvements to doc comments This has been factored out from https://github.com/rust-lang/rust/pull/58036 to only include changes to documentation comments (throughout the rustc codebase). r? @steveklabnik Once you're happy with this, maybe we could get it through with r=1, so it doesn't constantly get invalidated? (I'm not sure this will be an issue, but just in case...) Anyway, thanks for your advice so far!
2019-02-11Use hidden suggestions for unused imports lintEsteban Küber-3/+49
2019-02-11Add way to completely hide suggestion from cli outputEsteban Küber-3/+47
2019-02-11Never inline HideCodeAlways suggestionsEsteban Küber-1/+4
2019-02-11Expose hidden snippet suggestionsEsteban Küber-0/+43
2019-02-11Add way to hide suggestion snippet window from cli outputEsteban Küber-36/+84
2019-02-10rustc: doc commentsAlexander Regueiro-7/+7
2019-02-10Revert removed #![feature(nll)]Taiki Endo-0/+1
2019-02-09Auto merge of #57944 - estebank:unclosed-delim-the-quickening, r=oli-obkbors-2/+2
Deduplicate mismatched delimiter errors Delay unmatched delimiter errors until after the parser has run to deduplicate them when parsing and attempt recovering intelligently. Second attempt at #54029, follow up to #53949. Fix #31528.
2019-02-07Remove images' url to make it work even without internet connectionGuillaume Gomez-3/+1
2019-02-07Deduplicate mismatched delimiter errorsEsteban Küber-2/+2
Delay unmatched delimiter errors until after the parser has run to deduplicate them when parsing and attempt recovering intelligently.
2019-02-07librustc_errors => 2018Taiki Endo-45/+37
2019-01-26remove `_with_applicability` from suggestion fnsAndy Russell-156/+57
2019-01-26document `Applicability`Andy Russell-2/+18
2019-01-20Remove unnecessary dummy span checksEsteban Küber-1/+1
The emitter already verifies wether a given span note or span label can be emitted to the output. If it can't, because it is a dummy span, it will be either elided for labels or emitted as an unspanned note/help when applicable.
2019-01-19Rollup merge of #57699 - euclio:applicability-ify, r=petrochenkovMazdak Farrokhzad-34/+56
add applicability to remaining suggestions Fixes #50723. I noticed that the suggestion methods on `DiagnosticBuilder` weren't actually deprecated due to #57679. This PR deprecates them properly and fixes the remaining usages. There's also a PR for clippy at rust-lang/rust-clippy#3667.
2019-01-18Fix suggestions given mulitple bad lifetimesDan Robertson-4/+5
When given multiple lifetimes prior to type parameters in generic parameters, do not ICE and print the correct suggestion.
2019-01-17properly deprecate suggestion methodsAndy Russell-34/+56
2018-12-29Replace LockCell with atomic typesJohn Kåre Alsaker-8/+6
2018-12-25Remove licensesMark Rousskov-80/+0
2018-12-12Bump to 1.33.0Alex Crichton-1/+1
* Update bootstrap compiler * Update version to 1.33.0 * Remove some `#[cfg(stage0)]` annotations Actually updating the version number is blocked on updating Cargo
2018-12-07Rollup merge of #56516 - frewsxcv:frewsxcv-eq, r=Mark-Simulacrumkennytm-3/+3
Replace usages of `..i + 1` ranges with `..=i`. Before this change we were using old computer code techniques. After this change we use the new and improved computer code techniques.
2018-12-04adds DocTest filename variant, refactors doctest_offset out of source_map, ↵Matthew Russo-4/+5
fixes remaining test failures
2018-12-04Replace usages of `..i + 1` ranges with `..=i`.Corey Farwell-3/+3
2018-11-23Keep label on moved spans and point at macro invocation on parse errorEsteban Küber-0/+11
2018-11-08rustc: Request ansi colors if stderr isn't a ttyAlex Crichton-1/+7
Currently Cargo will always capture the output of rustc meaning that rustc is never hooked up to a tty. To retain colors Cargo uses the `fwdansi` crate to ensure that ansi color codes are translated to windows terminal methods (and ansi codes otherwise just go their natural route on Unix). Cargo passes `--color always` to rustc to ensure that using a pipe doesn't trick it into not emitting colors at all. It turns out, however, that `--color always` ends up still accidentally using the native shell api on native windows shells. The fix here is to instead pass `AlwaysAnsi` to `termcolor` instead of `Always`, ensuring that when `--color always` is passed to rustc and its output isn't a terminal, we're always generating ansi colors regardless of the platform. Closes #55769
2018-10-31Pass suggestions as impl Iterator instead of Vecljedrz-4/+4
2018-10-29Rename other occs of (Code/File)Map to Source(Map/File) #51574David Lavati-29/+29
2018-10-20Auto merge of #55014 - ljedrz:lazyboye_unwraps, r=matthewjasperbors-1/+1
Prefer unwrap_or_else to unwrap_or in case of function calls/allocations The contents of `unwrap_or` are evaluated eagerly, so it's not a good pick in case of function calls and allocations. This PR also changes a few `unwrap_or`s with `unwrap_or_default`. An added bonus is that in some cases this change also reveals if the object it's called on is an `Option` or a `Result` (based on whether the closure takes an argument).
2018-10-19Free some memory instead of just dropping elementsOliver Scherer-1/+2
2018-10-19Prefer `Default::default` over `FxHash*::default` in struct constructorsOliver Scherer-4/+4
2018-10-19Deprecate the `FxHashMap()` and `FxHashSet()` constructor function hackOliver Scherer-4/+4
2018-10-19Prefer unwrap_or_else to unwrap_or in case of function calls/allocationsljedrz-1/+1
2018-10-10A handful of random string-related improvementsljedrz-4/+4