www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 432] New: invalid expression causes compiler seg-fault

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

           Summary: invalid expression causes compiler seg-fault
           Product: D
           Version: 0.169
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla digitalmars.com
        ReportedBy: aziz.kerim gmail.com


bool a, b;
true && (a = b); // ok in DMD 168 and 169

// DMD 168 and 169 give this error: true && (a) is not an lvalue
true && a = b; // only DMD 169 seg-faults here


-- 
Oct 14 2006
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=432


fvbommel wxs.nl changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |ice-on-invalid-code
         OS/Version|Linux                       |All





 bool a, b;
 true && (a = b); // ok in DMD 168 and 169
irrellevant.
 // DMD 168 and 169 give this error: true && (a) is not an lvalue
 true && a = b; // only DMD 169 seg-faults here
This is equivalent to '(true && a) = b', not 'true && (a = b)' as you seem to imply by including the first bit of code. This means the error message is completely justified. The seg-fault is a bug, of course. (A null pointer dereference, judging by the error dialog) Also occurs on Windows, so set OS to 'All'. --
Oct 14 2006
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=432


deewiant gmail.com changed:

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







*** This bug has been marked as a duplicate of 410 ***


-- 
Oct 14 2006