summary refs log tree commit diff stats
path: root/compiler/sigmatch.nim
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/sigmatch.nim')
-rw-r--r--compiler/sigmatch.nim8
1 files changed, 6 insertions, 2 deletions
diff --git a/compiler/sigmatch.nim b/compiler/sigmatch.nim
index 75e3e5428..0dbd5e5f1 100644
--- a/compiler/sigmatch.nim
+++ b/compiler/sigmatch.nim
@@ -1840,7 +1840,9 @@ proc typeRel(c: var TCandidate, f, aOrig: PType,
       elif f.base.kind == tyNone:
         result = isGeneric
       else:
-        result = typeRel(c, f.base, a.base, flags)
+        let r = typeRel(c, f.base, a.base, flags)
+        if r >= isIntConv:
+          result = r
 
       if result != isNone:
         put(c, f, a)
@@ -1848,7 +1850,9 @@ proc typeRel(c: var TCandidate, f, aOrig: PType,
       if tfUnresolved in f.flags:
         result = typeRel(c, prev.base, a, flags)
       elif a.kind == tyTypeDesc:
-        result = typeRel(c, prev.base, a.base, flags)
+        let r = typeRel(c, prev.base, a.base, flags)
+        if r >= isIntConv:
+          result = r
       else:
         result = isNone