[Issue 14463] New: DMD crashes compiling module level immutable struct that takes an array in ctor
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Sun Apr 19 06:16:30 PDT 2015
https://issues.dlang.org/show_bug.cgi?id=14463
Issue ID: 14463
Summary: DMD crashes compiling module level immutable struct
that takes an array in ctor
Product: D
Version: D2
Hardware: x86
OS: Windows
Status: NEW
Severity: minor
Priority: P1
Component: DMD
Assignee: nobody at puremagic.com
Reporter: dzugaru at gmail.com
DMD on Windows v2.067 (seems to work on dpaste (presumably 2.065 there))
module main;
struct Boo
{
private int[1] c;
this(int[] x)
{
c = x;
}
}
immutable Boo a = Boo([1]);
Works without "immutable", works if declaration of "a" is moved below module
level, works with constructor accepting plain value.
--
More information about the Digitalmars-d-bugs
mailing list