Bug 682 – dmd segfault with vararg template

Status
RESOLVED
Resolution
FIXED
Severity
critical
Priority
P1
Component
dmd
Product
D
Version
D1 (retired)
Platform
x86
OS
Windows
Creation time
2006-12-12T22:18:00Z
Last change time
2014-02-15T13:20:12Z
Assigned to
bugzilla
Creator
davidl

Comments

Comment #0 by davidl — 2006-12-12T22:18:31Z
import std.stdio; template a(char[]name, T...){ char[] a(T t){ char[] localchar; foreach(a;t) { localchar=typeof(a).mangleof; } return localchar; } } void main() { a!("Adf"[],"afd",1234).a("Adf"[],"adf",1234); } dmd output: global.errors = 0, gag = 0 003CF3F4 .. type=char[] e1=003C80A0 003C80A0 string type=char[3] Assertion failure: '0' on line 775 in file 'expression.c' abnormal program termination dmd throw me:
Comment #1 by bugzilla — 2006-12-27T02:03:35Z
Fixed DMD 0.178