diff dmd/TypeExp.d @ 104:a1cf34da9ebe

+ TemplateDeclaration.toCBuffer + TypeExp.rvalue + TypeExp.toElem
author Trass3r
date Tue, 31 Aug 2010 16:35:41 +0200
parents 2e2a5c3f943a
children e28b18c23469
line wrap: on
line diff
--- a/dmd/TypeExp.d	Tue Aug 31 17:07:01 2010 +0400
+++ b/dmd/TypeExp.d	Tue Aug 31 16:35:41 2010 +0200
@@ -1,6 +1,8 @@
 module dmd.TypeExp;
 
 import dmd.Expression;
+import dmd.backend.TYM;
+import dmd.backend.Util;
 import dmd.backend.elem;
 import dmd.Type;
 import dmd.OutBuffer;
@@ -41,7 +43,7 @@
 
 	override void rvalue()
 	{
-		assert(false);
+		error("type %s has no value", toChars());
 	}
 
 	override void toCBuffer(OutBuffer buf, HdrGenState* hgs)
@@ -56,7 +58,11 @@
 
 	override elem* toElem(IRState* irs)
 	{
-		assert(false);
+		debug
+			writef("TypeExp.toElem()\n");
+
+		error("type %s is not an expression", toChars());
+		return el_long(TYint, 0);
 	}
 }