Thread overview
[Issue 7842] New: [ICE] (cgcs.c 517) with struct literal field increment
Oct 28, 2012
yebblies
[Issue 7842] ICE(cgcs.c) 517 with struct literal field increment
Jan 10, 2013
Andrej Mitrovic
April 06, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=7842

           Summary: [ICE] (cgcs.c 517) with struct literal field increment
           Product: D
           Version: D2
          Platform: x86
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody@puremagic.com
        ReportedBy: bearophile_hugs@eml.cc


--- Comment #0 from bearophile_hugs@eml.cc 2012-04-05 18:59:09 PDT ---
struct Foo { int x; }
void main() {
    Foo(5).x++;
}



DMD 2.059beta gives me:

Internal error: backend\cgcs.c 517

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
October 28, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=7842


yebblies <yebblies@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |ice
                 CC|                            |yebblies@gmail.com
           Platform|x86                         |All
            Version|D2                          |D1 & D2
         Depends on|                            |3008
         OS/Version|Windows                     |All


--- Comment #1 from yebblies <yebblies@gmail.com> 2012-10-28 23:17:39 EST ---
This has the same cause as issue 3008, the increment should be rejected during semantic as it is trying to operate on an rvalue, but isn't because DotVarExp::modifiableLvalue only checks that that _type_ is modifiable.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
January 10, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=7842


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

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |andrej.mitrovich@gmail.com
         Resolution|                            |DUPLICATE


--- Comment #2 from Andrej Mitrovic <andrej.mitrovich@gmail.com> 2013-01-10 05:57:00 PST ---
*** This issue has been marked as a duplicate of issue 3865 ***

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