[Issue 6780] New: Templated global property functions do not work

d-bugmail at puremagic.com d-bugmail at puremagic.com
Fri Oct 7 10:40:19 PDT 2011


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

           Summary: Templated global property functions do not work
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: rejects-valid
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody at puremagic.com
        ReportedBy: k.hara.pg at gmail.com


--- Comment #0 from Kenji Hara <k.hara.pg at gmail.com> 2011-10-07 10:39:32 PDT ---
@property int foo()(){ return 10; }

int g;
@property void bar()(int n){ g = n; }

void main()
{
    auto n = foo;
    assert(n == 10);

    bar = 10;
    assert(g == 10);
}

-- 
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