www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 2847] New: DMD raise internal error when struct includes type real variable (minor situation)

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

           Summary: DMD raise internal error when struct  includes type real
                    variable (minor situation)
           Product: D
           Version: 2.026
          Platform: PC
        OS/Version: Windows
            Status: NEW
          Severity: trivial
          Priority: P4
         Component: DMD
        AssignedTo: bugzilla digitalmars.com
        ReportedBy: hskwk inter7.jp


Internal error: ..\ztc\cod4.c 353

struct S { real v; }
S f() { S s; return s; }
const(S) g() { return f(); }


condition:
S includes `real' member variable (i.e. it will work when v is float or
double).
g() returns type const(S) (i.e. it will work when return type is S).
g() directly returns return value of f()  (i.e. it will work when return value
of f() is assigned in local variable).


-- 
Apr 17 2009
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2847


clugdbug yahoo.com.au changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|trivial                     |normal
           Keywords|                            |ice-on-valid-code
            Summary|DMD raise internal error    |ICE when struct  includes
                   |when struct  includes type  |type real variable (minor
                   |real variable (minor        |situation)
                   |situation)                  |





An ICE on valid code is never trivial!


-- 
Apr 17 2009
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2847


someanon yahoo.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P4                          |P1





v2.029 has the same bug.

Raise to P1, since the compiler crashes.


-- 
Apr 25 2009
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2847


Don <clugdbug yahoo.com.au> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |DUPLICATE





This is exactly the same as 2665, which is itself the same as 2560.

*** This issue has been marked as a duplicate of issue 2560 ***

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