Summary: Address of member of global struct isn't constant
           Product: D
           Version: 1.051
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD

--- Comment #0 from downs <> 2009-12-16 07:10:47 PST 
Created an attachment (id=524)
Make address of member of global struct constant

When taking the address of a member of a global struct, as in

struct S { int x; }

S s;

const int* p = &s.x;

The above fails on 1.051 with "Error: non-constant expression &s.x"

The attached patch fixes this.

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to