File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -5137,8 +5137,14 @@ RefCounted!(T, RefCountedAutoInitialize.no) refCounted(T)(T val)
51375137mixin template Proxy(alias a)
51385138{
51395139 private alias ValueType = typeof ({ return a; }());
5140+
5141+ /* Determine if 'T.a' can referenced via a const(T).
5142+ * Use T* as the parameter because 'scope' inference needs a fully
5143+ * analyzed T, which doesn't work when accessibleFrom() is used in a
5144+ * 'static if' in the definition of Proxy or T.
5145+ */
51405146 private enum bool accessibleFrom(T) =
5141- is (typeof ((ref T self){ cast (void )mixin (" self." ~ __traits(identifier, a)); }));
5147+ is (typeof ((T * self){ cast (void )mixin (" (* self) ." ~ __traits(identifier, a)); }));
51425148
51435149 static if (is (typeof (this ) == class ))
51445150 {
You can’t perform that action at this time.
0 commit comments