about summary refs log tree commit diff
path: root/src/test/ui/specialization/min_specialization
AgeCommit message (Collapse)AuthorLines
2023-01-11Move /src/test to /testsAlbert Larsan-546/+0
2023-01-08Normalize assumed_wf_types after wfchecking is complete, for better spansMichael Goulet-6/+6
2023-01-08Improve spans of non-WF implied bound typesMichael Goulet-14/+10
2022-08-22Auto merge of #100676 - lcnr:implied-bounds-yay, r=nikomatsakisbors-6/+12
implied bounds: explicitly state which types are assumed to be wf Adds a new query which maps each definition to the types which that definition assumes to be well formed. The intent is to make it easier to reason about implied bounds. This change should not influence the user-facing behavior of rustc. Notably, `borrowck` still only assumes that the function signature of associated functions is well formed while `wfcheck` assumes that the both the function signature and the impl trait ref is well formed. Not sure if that by itself can trigger UB or whether it's just annoying. As a next step, we can add `WellFormed` predicates to `predicates_of` of these items and can stop adding the wf bounds at each place which uses them. I also intend to move the computation from `assumed_wf_types` to `implied_bounds` into the `param_env` computation. This requires me to take a deeper look at `compare_predicate_entailment` which is currently somewhat weird wrt implied bounds so I am not touching this here. r? `@nikomatsakis`
2022-08-18Reword "Required because of the requirements on the impl of ..."Andy Wang-2/+2
2022-08-17implied_bounds: clarify our assumptionslcnr-6/+12
2022-07-15remove `impl_implied_bounds` from `FnCtxt`lcnr-5/+3
2022-07-01Improve spans for specialization errorMichael Goulet-11/+11
2022-07-01Shorten def_span for more items.Camille GILLOT-63/+25
2022-06-26Add regression test for #79224Yuki Okushi-0/+53
Signed-off-by: Yuki Okushi <jtitor@2k36.org>
2022-01-21Override rustc version in ui and mir-opt tests to get stable hashesThe 8472-1/+1
Building a dozen separate regexps for each test in compiletest consumes significant amounts of CPU cycles. Using `RUSTC_FORCE_INCR_COMP_ARTIFACT_HEADER` stabilizes hashes calcuated for the individual tests so no test-dependent normalization is needed. Hashes for the standard library still change so some normalizations are still needed.
2022-01-17Update term for use in more placeskadmin-1/+1
Replace use of `ty()` on term and use it in more places. This will allow more flexibility in the future, but slightly worried it allows items which are consts which only accept types.
2021-12-13Include rustc version in `rustc_span::StableCrateId`pierwill-1/+1
Normalize symbol hashes in compiletest. Remove DefId sorting
2021-09-30Elaborate predicates in min_specialization checksMatthew Jasper-0/+42
Supertraits of specialization markers could circumvent checks for min_specialization. Elaborating predicates prevents this.
2021-07-06Revert "Revert "Update tests""bjorn3-1/+1
This reverts commit 715c68fe90c6f1d0b3004ad18f16e0811f209992.
2021-06-07Revert "Update tests"bjorn3-1/+1
This reverts commit c76b1b031753fc08a18a3906d828683476c1e595.
2021-05-30Update testsbjorn3-1/+1
2021-03-31Track bound varsJack Huey-1/+1
2021-01-16fold_with not super_fold_with in TypeFoldable impl for PredicateJack Huey-1/+1
2021-01-16Remove PredicateKind::AtomJack Huey-1/+1
2020-09-25Move from {{closure}}#0 syntax to {closure#0} for (def) path componentsmarmeladema-1/+1
2020-09-02pretty: trim paths of unique symbolsDan Aloni-2/+2
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-07-27`PredicateKint` -> `PredicateKind`, the beginning of the endBastian Kauschke-1/+1
2020-07-19do not try fetching the ancestors of errored trait implsBastian Kauschke-0/+16
2020-03-15Consider well-formed predicates in min-specializationMatthew Jasper-0/+59
2020-03-15Implement soundness check for min_specializationMatthew Jasper-0/+382
2020-03-15Add attributes to allow specializing on traitsMatthew Jasper-0/+32