https://issues.dlang.org/show_bug.cgi?id=15425

RazvanN <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[email protected]

--- Comment #1 from RazvanN <[email protected]> ---
Maybe I am getting this wrong, but both S1 and S2 are free of indirections for
as far as I can tell. Even if the sizeof includes the context pointer, it is
not a user defined part of the struct.

hasIndirections does the following for structs:

static if (is(T == struct) || is(T == union))
    enum hasIndirections = anySatisfy!(.hasIndirections, FieldTypeTuple!T);

As you can see, all the field types are tested (the context pointer is not an
actual field of the struct), so in my opinion the output of your program is
correct.

--

Reply via email to