https://issues.dlang.org/show_bug.cgi?id=22254
Issue ID: 22254
Summary: Template instanted twice results in different
immutable qualifier
Product: D
Version: D2
Hardware: x86_64
OS: Linux
Status: NEW
Severity: regression
Priority: P1
Component: dmd
Assignee: [email protected]
Reporter: [email protected]
Consider the following code:
struct Template(T) { T t; }
Template!Bar a;
Template!Bar b;
immutable struct Bar { }
pragma(msg, typeof(a).stringof);
pragma(msg, typeof(b).stringof);
static assert(is(typeof(a) == typeof(b)));
Since 2.076.1, this assert fails, because it instantiates Template once with
"Bar" and once with "immutable Bar".
What the heck.
--