diff options
author | Michael Voronin <survivor.mail@gmail.com> | 2018-04-25 12:26:59 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-04-25 12:26:59 +0300 |
commit | 3949c9f977378ea3ab2b3c750f4dc2bc8d853022 (patch) | |
tree | e70fadb316aa330bd22694a71568316a103fecdd /compiler/semexprs.nim | |
parent | 17d3c6f3f32649c7cc295e964e2fcc3af99eac20 (diff) | |
parent | e931f3b5a9643e0d7ac45b88b0bddb32dda4c540 (diff) | |
download | Nim-3949c9f977378ea3ab2b3c750f4dc2bc8d853022.tar.gz |
Merge pull request #2 from nim-lang/devel
Pull 25-04-18
Diffstat (limited to 'compiler/semexprs.nim')
-rw-r--r-- | compiler/semexprs.nim | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/compiler/semexprs.nim b/compiler/semexprs.nim index 279b6cc57..6ad5d931d 100644 --- a/compiler/semexprs.nim +++ b/compiler/semexprs.nim @@ -663,7 +663,7 @@ proc resolveIndirectCall(c: PContext; n, nOrig: PNode; matches(c, n, nOrig, result) if result.state != csMatch: # try to deref the first argument: - if experimentalMode(c) and canDeref(n): + if implicitDeref in c.features and canDeref(n): n.sons[1] = n.sons[1].tryDeref initCandidate(c, result, t) matches(c, n, nOrig, result) @@ -1452,7 +1452,7 @@ proc semAsgn(c: PContext, n: PNode; mode=asgnNormal): PNode = typeMismatch(n.info, lhs.typ, rhsTyp) n.sons[1] = fitNode(c, le, rhs, n.info) - if not newDestructors: + if destructor notin c.features: if tfHasAsgn in lhs.typ.flags and not lhsIsResult and mode != noOverloadedAsgn: return overloadedAsgn(c, lhs, n.sons[1]) @@ -1884,7 +1884,7 @@ proc semMagic(c: PContext, n: PNode, s: PSym, flags: TExprFlags): PNode = result = newStrNodeT(renderTree(n[1], {renderNoComments}), n) result.typ = getSysType(tyString) of mParallel: - if not experimentalMode(c): + if parallel notin c.features: localError(n.info, "use the {.experimental.} pragma to enable 'parallel'") result = setMs(n, s) var x = n.lastSon |