diff options
author | Joseph Poirier <jdpoirier@gmail.com> | 2015-01-02 21:47:09 -0600 |
---|---|---|
committer | Joseph Poirier <jdpoirier@gmail.com> | 2015-01-02 21:47:09 -0600 |
commit | efe183861cc8416872e6c1a44f642e6b03049616 (patch) | |
tree | 84fb6bbc5a4f81c1055db9d98492c133886fc846 /compiler/semexprs.nim | |
parent | d15d9f41110a245b2b5a13bd8a882eeb79311acd (diff) | |
parent | 8f82205d12c7546b7369505b54d0157b4909fe6d (diff) | |
download | Nim-efe183861cc8416872e6c1a44f642e6b03049616.tar.gz |
Merge remote-tracking branch 'upstream/devel' into devel
Diffstat (limited to 'compiler/semexprs.nim')
-rw-r--r-- | compiler/semexprs.nim | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/compiler/semexprs.nim b/compiler/semexprs.nim index 89110a479..68921a15a 100644 --- a/compiler/semexprs.nim +++ b/compiler/semexprs.nim @@ -229,7 +229,7 @@ proc semConv(c: PContext, n: PNode): PNode = return n result = newNodeI(nkConv, n.info) - var targetType = semTypeNode(c, n.sons[0], nil) + var targetType = semTypeNode(c, n.sons[0], nil).skipTypes({tyTypeDesc}) maybeLiftType(targetType, c, n[0].info) result.addSon copyTree(n.sons[0]) var op = semExprWithType(c, n.sons[1]) @@ -780,7 +780,6 @@ proc semIndirectOp(c: PContext, n: PNode, flags: TExprFlags): PNode = if tfNoSideEffect notin t.flags: incl(c.p.owner.flags, sfSideEffect) elif t != nil and t.kind == tyTypeDesc: if n.len == 1: return semObjConstr(c, n, flags) - let destType = t.skipTypes({tyTypeDesc, tyGenericInst}) return semConv(c, n) else: result = overloadedCallOpr(c, n) @@ -928,7 +927,6 @@ proc readTypeParameter(c: PContext, typ: PType, let ty = if typ.kind == tyGenericInst: typ.skipGenericAlias else: (internalAssert(typ.kind == tyCompositeTypeClass); typ.sons[1].skipGenericAlias) - #debug ty let tbody = ty.sons[0] for s in countup(0, tbody.len-2): let tParam = tbody.sons[s] |