www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 10907] New: It is impossible to pack a structure with shared object into a tuple.

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

           Summary: It is impossible to pack a structure with shared
                    object into a tuple.
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Phobos
        AssignedTo: nobody puremagic.com
        ReportedBy: japplegame gmail.com


--- Comment #0 from Jack Applegame <japplegame gmail.com> 2013-08-26 16:13:18
PDT ---
Example:

import std.typecons;

class Foo {}

struct A {
    shared Foo foo;
}

void main() {
    auto a = tuple(new shared Foo); // ОК
    auto b = tuple(A()); // Error: static assert "unable" to format shared
objects"
}

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