summary refs log tree commit diff stats
path: root/compiler/ast.nim
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/ast.nim')
-rw-r--r--compiler/ast.nim4
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/ast.nim b/compiler/ast.nim
index 13df058e7..5f6b658cf 100644
--- a/compiler/ast.nim
+++ b/compiler/ast.nim
@@ -1359,9 +1359,9 @@ proc getStrOrChar*(a: PNode): string =
 proc isGenericRoutine*(s: PSym): bool = 
   case s.kind
   of skProc, skTemplate, skMacro, skIterator, skMethod, skConverter:
-    result = s.ast != nil and s.ast[genericParamsPos].kind != nkEmpty
+    result = sfFromGeneric in s.flags
   else: nil
-  
+
 proc isRoutine*(s: PSym): bool {.inline.} =
   result = s.kind in {skProc, skTemplate, skMacro, skIterator, skMethod,
                       skConverter}