about summary refs log tree commit diff
path: root/src/test/ui/span/send-is-not-static-std-sync.stderr
AgeCommit message (Collapse)AuthorLines
2023-01-11Move /src/test to /testsAlbert Larsan-72/+0
2021-09-25Use larger span for adjustments on method callsAaron Hill-5/+5
Currently, we use a relatively 'small' span for THIR expressions generated by an 'adjustment' (e.g. an autoderef, autoborrow, unsizing). As a result, if a borrow generated by an adustment ends up causing a borrowcheck error, for example: ```rust let mut my_var = String::new(); let my_ref = &my_var my_var.push('a'); my_ref; ``` then the span for the mutable borrow may end up referring to only the base expression (e.g. `my_var`), rather than the method call which triggered the mutable borrow (e.g. `my_var.push('a')`) Due to a quirk of the MIR borrowck implementation, this doesn't always get exposed in migration mode, but it does in many cases. This commit makes THIR building consistently use 'larger' spans for adjustment expressions The intent of this change it make it clearer to users when it's the specific way in which a variable is used (for example, in a method call) that produdes a borrowcheck error. For example, an error message claiming that a 'mutable borrow occurs here' might be confusing if it just points at a usage of a variable (e.g. `my_var`), when no `&mut` is in sight. Pointing at the entire expression should help to emphasize that the method call itself is responsible for the mutable borrow. In several cases, this makes the `#![feature(nll)]` diagnostic output match up exactly with the default (migration mode) output. As a result, several `.nll.stderr` files end up getting removed entirely.
2020-09-02pretty: trim paths of unique symbolsDan Aloni-1/+1
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.
2019-04-22update tests for migrate mode by defaultMatthew Jasper-26/+37
2019-04-18hide `--explain` hint if error has no extended infoAndy Russell-1/+1
2019-03-11Update testsVadim Petrochenkov-3/+3
2018-12-25Remove licensesMark Rousskov-6/+6
2018-05-25rust-lang/rust#51025: improve test robustness so that they work under NLL too.Felix S. Klock II-7/+7
2018-03-14update testsGuillaume Gomez-2/+2
2018-02-26Update UI testsVadim Petrochenkov-3/+3
2018-02-26Update UI testsVadim Petrochenkov-15/+15
2018-02-25Update ui testsGuillaume Gomez-0/+2
2017-12-14Point at var in short lived borrowsEsteban Küber-23/+26
2017-11-24Merge cfail and ui tests into ui testsOliver Schneider-6/+6
2017-07-02Revert "Change error count messages"Ariel Ben-Yehuda-1/+1
This reverts commit 5558c64f33446225739c1153b43d2e309bb4f50e.
2017-05-27Add new error codes and update testsGuillaume Gomez-3/+3
2017-05-24Change error count messagesMichael Kohl-1/+1
See #33525 for details.
2016-11-01Improve "Doesn't live long enough" errorMikhail Modin-0/+56
case with different lifetime with spans