[Issue 11843] Template instantiated twice: failed semantic analysis
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Mon Dec 30 03:48:11 PST 2013
https://d.puremagic.com/issues/show_bug.cgi?id=11843
--- Comment #2 from Nicolas Sicard <dransic at gmail.com> 2013-12-30 03:48:06 PST ---
(In reply to comment #1)
> https://github.com/D-Programming-Language/dmd/pull/3049
I have tested your patch, but now bar1 and bar2 have the same type even if
instantiated with two different symbol aliases.
---
void main()
{
struct Foo
{
int x[string];
}
struct Bar(alias foo) {}
enum foo1 = Foo(["a": 1]);
enum foo2 = Foo(["b": -1]);
static assert(!__traits(isSame, foo1, foo2));
enum bar1 = Bar!foo1();
enum bar2 = Bar!foo2();
static assert(is(typeof(bar1) == typeof(bar2)));
}
---
--
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list