summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--compiler/semtypinst.nim5
1 files changed, 3 insertions, 2 deletions
diff --git a/compiler/semtypinst.nim b/compiler/semtypinst.nim
index 271a01266..33de40f34 100644
--- a/compiler/semtypinst.nim
+++ b/compiler/semtypinst.nim
@@ -352,8 +352,9 @@ proc replaceTypeVarsTAux(cl: var TReplTypeVars, t: PType): PType =
     result = handleGenericInvokation(cl, t)
 
   of tyGenericBody:
-    internalError(cl.info, "ReplaceTypeVarsT: tyGenericBody" )
-    result = replaceTypeVarsT(cl, lastSon(t))
+    localError(cl.info, errCannotInstantiateX, typeToString(t))
+    result = t
+    #result = replaceTypeVarsT(cl, lastSon(t))
 
   of tyFromExpr:
     if cl.allowMetaTypes: return