Bug 1799 – Wrong constant folding in static array types.

Status
RESOLVED
Resolution
DUPLICATE
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D1 (retired)
Platform
x86
OS
Linux
Creation time
2008-01-22T09:05:00Z
Last change time
2014-02-24T15:32:39Z
Keywords
accepts-invalid
Assigned to
bugzilla
Creator
aziz.koeksal

Comments

Comment #0 by aziz.koeksal — 2008-01-22T09:05:33Z
char[1i] a; // char[0] char[1-1i] b; // char[1] char[2+1i] c; // char[2] const x = 2+1i; // typeof(x) == cdouble char[x] d; // char[2] It looks like the real part of the complex number is always chopped off. Should be an error in the constant folding code.
Comment #1 by aziz.koeksal — 2008-01-22T09:06:54Z
*** This bug has been marked as a duplicate of 1798 ***