diff options
author | Araq <rumpf_a@web.de> | 2018-08-22 12:35:46 +0200 |
---|---|---|
committer | Araq <rumpf_a@web.de> | 2018-08-22 12:35:46 +0200 |
commit | 64517445ea2347f29d91de44fe46ff78a6f655ab (patch) | |
tree | 630493227c0d7c953da3b0af087615d1727829db /compiler/suggest.nim | |
parent | 9047c3f5821043a348e289335ff00b1147a34f88 (diff) | |
download | Nim-64517445ea2347f29d91de44fe46ff78a6f655ab.tar.gz |
even more strict isNil handling for strings/seqs in order to detect bugs
Diffstat (limited to 'compiler/suggest.nim')
-rw-r--r-- | compiler/suggest.nim | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/suggest.nim b/compiler/suggest.nim index a21d64338..3d3cd2484 100644 --- a/compiler/suggest.nim +++ b/compiler/suggest.nim @@ -47,7 +47,7 @@ template origModuleName(m: PSym): string = m.name.s proc findDocComment(n: PNode): PNode = if n == nil: return nil - if not isNil(n.comment): return n + if n.comment.len > 0: return n if n.kind in {nkStmtList, nkStmtListExpr, nkObjectTy, nkRecList} and n.len > 0: result = findDocComment(n.sons[0]) if result != nil: return |