Bug 1321 – Deadlock when setting length for complex dynamic array type

Status
RESOLVED
Resolution
DUPLICATE
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D1 (retired)
Platform
x86
OS
Windows
Creation time
2007-07-07T08:41:00Z
Last change time
2014-02-16T15:26:23Z
Keywords
wrong-code
Assigned to
bugzilla
Creator
d0ccrazy

Comments

Comment #0 by d0ccrazy — 2007-07-07T08:41:40Z
The following code produces a deadlock at runtime (100% cpu) for DMD 1.018 and some earlier versions I tested (1.015, 1.017): int main(char[][] args) { int[char[]][] a; a.length = 1; return 0; } However, the following works, int main(char[][] args) { int[char[]][1] a; a[0]["test"] = 1; return 0; } as does this: struct S { int[char[]] v; } int main(char[][] args) { S[] a; a.length = 1; a[0].v["test"] = 1; return 0; }
Comment #1 by matti.niemenmaa+dbugzilla — 2007-07-07T09:43:27Z
*** This bug has been marked as a duplicate of 929 ***