[Issue 3293] New: A few more bugs with template mixins with identifiers
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Thu Sep 3 13:23:56 PDT 2009
http://d.puremagic.com/issues/show_bug.cgi?id=3293
Summary: A few more bugs with template mixins with identifiers
Product: D
Version: 2.031
Platform: Other
OS/Version: Windows
Status: NEW
Keywords: ice-on-valid-code, rejects-valid
Severity: normal
Priority: P2
Component: DMD
AssignedTo: nobody at puremagic.com
ReportedBy: 2korden at gmail.com
template ReferenceType(T)
{
alias T* ReferenceType;
}
struct SomeRange(T, alias Storage = 0)
{
bool foo()
{
return guard == guard; // bug 1: replace == with is and DMD crashes
with no output
}
enum guard = cast(ReferenceType!(T))SomeContainer!(T, Storage).guard;
}
struct SomeContainer(T, alias Storage = 0)
{
auto opSlice() // bug 2: replace auto with SomeRange!(T, Storage) and
get an ICE
{
return SomeRange!(T, Storage)();
}
enum ReferenceType!(T) guard =
cast(ReferenceType!(T))cast(void*)0xFEFEFEFE; // bug 3: remove guard type
and DMD crashes with no output
}
class A
{
SomeRange!(int, 0) test() // bug 4: 0 is not omissible
{
return SomeContainer!(int)()[];
}
}
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list