www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 9182] New: [ICE](glue.c line 1235) With static struct fields

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=9182

           Summary: [ICE](glue.c line 1235) With static struct fields
           Product: D
           Version: D2
          Platform: x86
        OS/Version: Windows
            Status: NEW
          Keywords: rejects-valid
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody puremagic.com
        ReportedBy: bearophile_hugs eml.cc



struct Foo {
    static immutable F = Foo();
    static immutable Foo[1] foos1 = [F];
    static immutable foos3 = [F];
}
void main() {}



DMD 2.061alpha:

Assertion failure: '0' on line 1235 in file 'glue.c'

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Dec 18 2012
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=9182


yebblies <yebblies gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |yebblies gmail.com
           Platform|x86                         |All
            Summary|[ICE](glue.c line 1235)     |Forward reference error
                   |With static struct fields   |with static immutable
                   |                            |struct members
         OS/Version|Windows                     |All



With 2.062 head it doesn't ice.

Now prints:

testx.d(3): Error: forward reference of variable F

or

testx.d(4): Error: variable testx.Foo.foos3 had semantic errors when compiling

If you move the lines around.  I suspect this is a dupe of one of the other
forward reference bugs.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jan 14 2013
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=9182


Andrej Mitrovic <andrej.mitrovich gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |andrej.mitrovich gmail.com



21:55:30 PST ---

 With 2.062 head it doesn't ice.
Current 2.062 head (b58ef83b22e4e4375e83aeb3f9e1ba18774f0688): Without -g: test.d(4): Error: variable test.Foo.foos3 had semantic errors when compiling With -g crash and: ty = 35, '_error_' -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Feb 09 2013