mirror of
https://github.com/nim-lang/Nim.git
synced 2026-09-08 22:47:27 +00:00
@@ -390,7 +390,8 @@ proc semConv(c: PContext, n: PNode; flags: TExprFlags = {}, expectedType: PType
|
||||
elif op.kind in {nkPar, nkTupleConstr} and targetType.kind == tyTuple:
|
||||
op = fitNode(c, targetType, op, result.info)
|
||||
of convNotNeedeed:
|
||||
message(c.config, n.info, hintConvFromXtoItselfNotNeeded, result.typ.typeToString)
|
||||
if efNoSem2Check notin flags:
|
||||
message(c.config, n.info, hintConvFromXtoItselfNotNeeded, result.typ.typeToString)
|
||||
of convNotLegal:
|
||||
result = fitNode(c, result.typ, result[1], result.info)
|
||||
if result == nil:
|
||||
|
||||
@@ -2060,7 +2060,7 @@ proc localConvMatch(c: PContext, m: var TCandidate, f, a: PType,
|
||||
if result != nil:
|
||||
if result.typ == nil: return nil
|
||||
# bug #13378, ensure we produce a real generic instantiation:
|
||||
result = c.semExpr(c, call)
|
||||
result = c.semExpr(c, call, {efNoSem2Check})
|
||||
# resulting type must be consistent with the other arguments:
|
||||
var r = typeRel(m, f[0], result.typ)
|
||||
if r < isGeneric: return nil
|
||||
|
||||
Reference in New Issue
Block a user