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


Brad Roberts <bra...@puremagic.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|2.058                       |---

Andrei Alexandrescu <and...@metalanguage.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
         AssignedTo|and...@metalanguage.com     |bugzi...@digitalmars.com


--- Comment #1 from Andrei Alexandrescu <and...@metalanguage.com> 2012-01-22 
08:16:23 PST ---
This is a compiler issue that I reduced to this:


struct S
{
    int member;
    @property ref int refCountedPayload() { return member; }
    alias refCountedPayload this;
}

void foo(S, T, Tdummy=void)(ref const S source, ref const T target) @trusted
pure nothrow
{
}
// for shared objects
void foo(S, T)(ref const shared S source, ref const shared T target) @trusted
pure nothrow
{
    alias foo!(shared(S), shared(T), void) ptsTo;  // do instantiate explicitly
    ptsTo(source, target);
}

void bar(T)(ref T lhs, ref T rhs) @trusted pure nothrow
{
    foo(lhs, rhs);
}

void main() {
    S a, b;
    bar(a, b);
}

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

Reply via email to