rust/src/test/ui/generic
Dan Aloni 07e7823c01 pretty: trim paths of unique symbols
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-09-02 22:26:37 +03:00
..
generic-arg-mismatch-recover.rs Report all errors in check_generic_arg_count 2020-02-22 00:27:44 +00:00
generic-arg-mismatch-recover.stderr Report all errors in check_generic_arg_count 2020-02-22 00:27:44 +00:00
generic-extern-lifetime.rs Remove licenses 2018-12-25 21:08:33 -07:00
generic-extern-lifetime.stderr review comments: wording 2020-02-05 10:32:01 -08:00
generic-extern.rs Remove licenses 2018-12-25 21:08:33 -07:00
generic-extern.stderr Make wording less confusing 2019-09-11 00:29:35 +01:00
generic-impl-less-params-with-defaults.rs Remove licenses 2018-12-25 21:08:33 -07:00
generic-impl-less-params-with-defaults.stderr Remove licenses 2018-12-25 21:08:33 -07:00
generic-impl-more-params-with-defaults.rs Remove licenses 2018-12-25 21:08:33 -07:00
generic-impl-more-params-with-defaults.stderr Remove licenses 2018-12-25 21:08:33 -07:00
generic-lifetime-trait-impl.rs Remove licenses 2018-12-25 21:08:33 -07:00
generic-lifetime-trait-impl.stderr Update tests 2019-03-11 23:10:26 +03:00
generic-no-mangle.fixed Audit uses of span_suggestion_short 2020-07-02 15:18:33 +09:00
generic-no-mangle.rs Audit uses of span_suggestion_short 2020-07-02 15:18:33 +09:00
generic-no-mangle.stderr Audit uses of span_suggestion_short 2020-07-02 15:18:33 +09:00
generic-non-trailing-defaults.rs Remove licenses 2018-12-25 21:08:33 -07:00
generic-non-trailing-defaults.stderr Remove licenses 2018-12-25 21:08:33 -07:00
generic-param-attrs.rs Rollup merge of #62133 - petrochenkov:norustc, r=eddyb 2019-07-05 20:26:54 +02:00
generic-type-less-params-with-defaults.rs Remove licenses 2018-12-25 21:08:33 -07:00
generic-type-less-params-with-defaults.stderr Remove licenses 2018-12-25 21:08:33 -07:00
generic-type-more-params-with-defaults.rs Remove licenses 2018-12-25 21:08:33 -07:00
generic-type-more-params-with-defaults.stderr Remove licenses 2018-12-25 21:08:33 -07:00
generic-type-params-forward-mention.rs Remove licenses 2018-12-25 21:08:33 -07:00
generic-type-params-forward-mention.stderr Remove licenses 2018-12-25 21:08:33 -07:00
generic-type-params-name-repr.rs pretty: trim paths of unique symbols 2020-09-02 22:26:37 +03:00
generic-type-params-name-repr.stderr pretty: trim paths of unique symbols 2020-09-02 22:26:37 +03:00
param-in-ct-in-ty-param-default.rs forbid generic params inside of anon consts in ty defaults 2020-07-27 16:33:23 +02:00
param-in-ct-in-ty-param-default.stderr forbid generic params inside of anon consts in ty defaults 2020-07-27 16:33:23 +02:00