[Issue 3469] ICE(func.c): Regression. Calling non-template function as a template, from another module
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Tue Nov 3 03:45:49 PST 2009
http://d.puremagic.com/issues/show_bug.cgi?id=3469
Don <clugdbug at yahoo.com.au> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |patch
--- Comment #2 from Don <clugdbug at yahoo.com.au> 2009-11-03 03:45:48 PST ---
PATCH against DMD2.036. Passes the DMD test suite + phobos unittests.
Expression.c, DotTemplateInstanceExp::semantic(). Ensure it's a template BEFORE
running the semantic pass.
Index: expression.c
===================================================================
--- expression.c (revision 234)
+++ expression.c (working copy)
@@ -6082,6 +6082,14 @@
goto Lerr;
}
s = s2;
+
+ td = s->toAlias()->isTemplateDeclaration();
+ if (!td)
+ {
+ error("%s is not a template", id->toChars());
+ goto Lerr;
+ }
+
s->semantic(sc);
s = s->toAlias();
td = s->isTemplateDeclaration();
--
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