You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This compiles today since the pointer returned from data[0] does not require a complete type. However, once non-member operator[] is possible, the compiler has to look into Wrap<Incomplete>, whether it has a hidden friend operator[] which is a better match than the one from std::vector. While instantiating Wrap<Incomplete>, T x leads to an error, making the above example ill-formed.
The text was updated successfully, but these errors were encountered:
Similar issues exist and
operator[]
would be no exception:This compiles today since the pointer returned from
data[0]
does not require a complete type. However, once non-memberoperator[]
is possible, the compiler has to look intoWrap<Incomplete>
, whether it has a hidden friendoperator[]
which is a better match than the one fromstd::vector
. While instantiatingWrap<Incomplete>
,T x
leads to an error, making the above example ill-formed.The text was updated successfully, but these errors were encountered: