Skip to content

Commit

Permalink
extend comment
Browse files Browse the repository at this point in the history
  • Loading branch information
lcnr committed Feb 27, 2024
1 parent a975996 commit eaf3fdd
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tests/ui/type-alias-impl-trait/wf-check-definition-site.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// `Opaque<'a> = Static<&'a str>`, vs
// `Opaque<'a> = Static<&'static str>`.
//
// The hidden type of the opaque ends up as `Static<'?0 str>`. When
// computing member constraints we end up choosing `'a` for `?0` unless
// `?0` is already required to outlive `'a`. We achieve this by checking
// that `Static<'?0 str>` is well-formed.
#![feature(type_alias_impl_trait)]

struct Static<T: 'static>(T);
Expand Down

0 comments on commit eaf3fdd

Please sign in to comment.