[Issue 6776] attributes injected via pure template mixin but not class mixin

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sun Feb 12 15:52:36 PST 2012


http://d.puremagic.com/issues/show_bug.cgi?id=6776


Stewart Gordon <smjg at iname.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |smjg at iname.com
         Resolution|                            |INVALID


--- Comment #1 from Stewart Gordon <smjg at iname.com> 2012-02-12 15:52:33 PST ---
There's no such thing as a class mixin.  One mixes in template instances, not
classes.  Since a class template is just syntactic sugar for a template with an
eponymous class as its only member, the compiler expands it to:

    class D {
        class C {
            bool val;
        }
    }

So of course there's no such thing as d.val.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list