diff options
Diffstat (limited to 'compiler')
-rw-r--r-- | compiler/semcall.nim | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/compiler/semcall.nim b/compiler/semcall.nim index 3981d256f..4240bc603 100644 --- a/compiler/semcall.nim +++ b/compiler/semcall.nim @@ -725,7 +725,8 @@ proc semResolvedCall(c: PContext, x: var TCandidate, result = x.call instGenericConvertersSons(c, result, x) result[0] = newSymNode(finalCallee, getCallLineInfo(result[0])) - result.typ = finalCallee.typ.returnType + if finalCallee.magic notin {mArrGet, mArrPut}: + result.typ = finalCallee.typ.returnType updateDefaultParams(result) proc canDeref(n: PNode): bool {.inline.} = |