about summary refs log tree commit diff
path: root/src/test/ui/coherence
AgeCommit message (Collapse)AuthorLines
2023-01-11Move /src/test to /testsAlbert Larsan-4386/+0
2023-01-01reduce spans for `unsafe impl` errorsLukas Markeffsky-2/+2
2022-11-21Allow opaque types in trait impl headers and rely on coherence to reject ↵Oli Scherer-32/+4
unsound cases
2022-11-18deduplicate testslcnr-59/+0
2022-11-10Don't print full paths in overlap errorsMichael Goulet-15/+15
2022-10-30better error for rustc_strict_coherence misuseMichael Goulet-0/+17
2022-10-20Add fix suggestions for E0199, E0200, and E0569Nicolas Barrios-0/+12
2022-10-08Rollup merge of #102514 - b-naber:binder-print-fixes, r=jackh726Michael Howell-2/+2
Don't repeat lifetime names from outer binder in print Fixes https://github.com/rust-lang/rust/issues/102392 Fixes https://github.com/rust-lang/rust/issues/102414 r? ```@lcnr```
2022-10-01bless ui testsMaybe Waffle-12/+12
2022-09-30bless testsb-naber-2/+2
2022-09-23Allow more !Copy implsLeón Orell Valerian Liehr-2/+78
2022-08-23Permit negative impls coherence to take advantage of implied boundsSantiago Pastorino-14/+3
2022-08-20Use separate infcx to solve obligations during negative coherenceMichael Goulet-2/+18
2022-08-18Reword "Required because of the requirements on the impl of ..."Andy Wang-2/+2
2022-08-15Rollup merge of #100514 - compiler-errors:issue-100191, r=spastorinoMatthias Krüger-0/+59
Delay span bug when failing to normalize negative coherence impl subject due to other malformed impls Fixes #100191 r? ``@spastorino``
2022-08-13Delay span bug when failing to normalize negative coherence impl subject due ↵Michael Goulet-0/+59
to other malformed impls
2022-07-28orphan check: remove const generics fixmelcnr-0/+29
2022-07-25Restore Opaque behavior to coherence checkMichael Goulet-0/+44
2022-07-10Remove duplicate notes from error on inter-crate ambiguous impl of traits ↵rhysd-1/+33
(fix #99092)
2022-07-01Auto merge of #98781 - GuillaumeGomez:rollup-798kb8u, r=GuillaumeGomezbors-2/+2
Rollup of 5 pull requests Successful merges: - #97249 (`<details>`/`<summary>` UI fixes) - #98418 (Allow macOS to build LLVM as shared library) - #98460 (Use CSS variables to handle theming) - #98497 (Improve some inference diagnostics) - #98708 (rustdoc: fix 98690 Panic if invalid path for -Z persist-doctests) Failed merges: - #98761 (more `need_type_info` improvements) r? `@ghost` `@rustbot` modify labels: rollup
2022-07-01Don't point at Self type if we can't find an infer variable in ambiguous ↵Michael Goulet-2/+2
trait predicate
2022-07-01Shorten def_span for more items.Camille GILLOT-17/+6
2022-06-22Perform coherence checking per impl.Camille GILLOT-107/+107
2022-06-16 fix one more case of trailing spaceklensy-7/+7
2022-06-01update explicit impls error msglcnr-6/+6
2022-05-18Rollup merge of #95979 - lcnr:coherence-docs, r=compiler-errorsDylan DPC-0/+82
update coherence docs, fix generator + opaque type ICE the world is confusing, this makes it slightly less so
2022-05-10update coherence docs, fix opaque type + generator icelcnr-0/+82
2022-04-21make `E0117` error clearTakayuki Maeda-24/+24
2022-03-25Auto merge of #95082 - spastorino:overlap-inherent-impls, r=nikomatsakisbors-0/+47
Overlap inherent impls r? `@nikomatsakis` Closes #94526
2022-03-24Where bounds are checked on inherent implsSantiago Pastorino-0/+25
2022-03-22better errors when a Copy impl is not coherentMichael Goulet-0/+58
2022-03-18Fix inherent impls on negative coherenceSantiago Pastorino-0/+22
2022-03-17This test now worksSantiago Pastorino-13/+2
2022-03-17Make negative coherence work when there's impl negative on super predicatesSantiago Pastorino-0/+18
2022-03-16Add double negative trait test caseSantiago Pastorino-0/+12
2022-02-14Add failing test that should passSantiago Pastorino-0/+23
2022-02-14Properly check regions on negative overlap checkSantiago Pastorino-2/+19
2022-01-31Move overlap_mode into trait level attribute + feature flagSantiago Pastorino-12/+9
2022-01-21Implement stable with negative coherence modeSantiago Pastorino-0/+26
2021-12-10manually implement `Hash` for `DefId`Andre Bogus-11/+11
This also reorders the fields to reduce the assembly operations for hashing and changes two UI tests that depended on the former ordering because of hashmap iteration order.
2021-11-20Point at source of trait bound obligations in more placesEsteban Kuber-5/+0
Be more thorough in using `ItemObligation` and `BindingObligation` when evaluating obligations so that we can point at trait bounds that introduced unfulfilled obligations. We no longer incorrectly point at unrelated trait bounds (`substs-ppaux.verbose.stderr`). In particular, we now point at trait bounds on method calls. We no longer point at "obvious" obligation sources (we no longer have a note pointing at `Trait` saying "required by a bound in `Trait`", like in `associated-types-no-suitable-supertrait*`). Address part of #89418.
2021-11-10no overlap errors after failing the orphan checklcnr-153/+108
2021-10-24Point at overlapping impls when type annotations are neededEsteban Kuber-1/+8
2021-10-22Hide negative coherence checks under negative_impls feature flagSantiago Pastorino-0/+32
2021-10-22Be sure that we do not allow too muchSantiago Pastorino-0/+36
2021-10-22Add rustc_strict_coherence attribute and use it to check overlapSantiago Pastorino-0/+49
2021-10-20Test that if we promise to not impl what would overlap it doesn't actually ↵Santiago Pastorino-0/+19
overlap
2021-09-20Don't use projection cache or candidate cache in intercrate modeAaron Hill-0/+1
Fixes #88969 It appears that *just* disabling the evaluation cache (in #88994) leads to other issues involving intercrate mode caching. I suspect that since we now always end up performing the full evaluation in intercrate mode, we end up 'polluting' the candidate and projection caches with results that depend on being in intercrate mode in some way. Previously, we might have hit a cached evaluation (stored during non-intercrate mode), and skipped doing this extra work in intercrate mode. The whole situation with intercrate mode caching is turning into a mess. Ideally, we would remove intercrate mode entirely - however, this might require waiting on Chalk.
2021-09-16Auto merge of #88719 - estebank:point-at-arg-for-obligation, r=nagisabors-1/+3
Point at argument instead of call for their obligations When an obligation is introduced by a specific `fn` argument, point at the argument instead of the `fn` call if the obligation fails to be fulfilled. Move the information about pointing at the call argument expression in an unmet obligation span from the `FulfillmentError` to a new `ObligationCauseCode`. When giving an error about an obligation introduced by a function call that an argument doesn't fulfill, and that argument is a block, add a span_label pointing at the innermost tail expression. Current output: ``` error[E0425]: cannot find value `x` in this scope --> f10.rs:4:14 | 4 | Some(x * 2) | ^ not found in this scope error[E0277]: expected a `FnOnce<({integer},)>` closure, found `Option<_>` --> f10.rs:2:31 | 2 | let p = Some(45).and_then({ | ______________________--------_^ | | | | | required by a bound introduced by this call 3 | | |x| println!("doubling {}", x); 4 | | Some(x * 2) | | ----------- 5 | | }); | |_____^ expected an `FnOnce<({integer},)>` closure, found `Option<_>` | = help: the trait `FnOnce<({integer},)>` is not implemented for `Option<_>` ``` Previous output: ``` error[E0425]: cannot find value `x` in this scope --> f10.rs:4:14 | 4 | Some(x * 2) | ^ not found in this scope error[E0277]: expected a `FnOnce<({integer},)>` closure, found `Option<_>` --> f10.rs:2:22 | 2 | let p = Some(45).and_then({ | ^^^^^^^^ expected an `FnOnce<({integer},)>` closure, found `Option<_>` | = help: the trait `FnOnce<({integer},)>` is not implemented for `Option<_>` ``` Partially address #27300. Will require rebasing on top of #88546.
2021-09-16Point at call span that introduced obligation for the argEsteban Kuber-1/+3