Bug 872 – Assertion in expression.c caused by taking typeof of "this.outer" in nested classes.

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D1 (retired)
Platform
x86
OS
Windows
Creation time
2007-01-22T18:05:00Z
Last change time
2014-02-15T13:13:28Z
Keywords
ice-on-valid-code
Assigned to
bugzilla
Creator
tknott

Comments

Comment #0 by tknott — 2007-01-22T18:05:40Z
Comment #1 by tknott — 2007-01-22T18:11:22Z
Sorry, I accidentally hit "enter" before providing a description. Anyways, the following example (which seems to be valid D code) will cause an assertion in the DMD frontend code (Assertion failure: 'global.errors || var' on line 1904 in file 'expression.c') upon compilation. This bug affects both DMD and GDC. Test case: class ExOuter { class ExInner { this() { typeof(this.outer) X; } } } void main() {}
Comment #2 by thomas-dloop — 2007-01-23T07:45:52Z
Comment #3 by bugzilla — 2007-02-12T03:40:11Z
Fixed DMD 1.005