diff options
author | Andreas Rumpf <rumpf_a@web.de> | 2018-08-13 12:29:03 +0200 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2018-08-13 12:29:03 +0200 |
commit | 7f49364fd073072c4db42428b1f67873a6e26d24 (patch) | |
tree | 4ae9badf2369a861cc2c9f79aaf33e038f7de0e5 /lib/impure/nre | |
parent | dae5450947e93e2e5222ae2710874186bf27bf39 (diff) | |
download | Nim-7f49364fd073072c4db42428b1f67873a6e26d24.tar.gz |
make more tests green
Diffstat (limited to 'lib/impure/nre')
-rw-r--r-- | lib/impure/nre/private/util.nim | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/lib/impure/nre/private/util.nim b/lib/impure/nre/private/util.nim index 12d2506ea..a3ae84007 100644 --- a/lib/impure/nre/private/util.nim +++ b/lib/impure/nre/private/util.nim @@ -10,11 +10,7 @@ proc fget*[K, V](self: Table[K, V], key: K): V = const Ident = {'a'..'z', 'A'..'Z', '0'..'9', '_', '\128'..'\255'} const StartIdent = Ident - {'0'..'9'} -proc checkNil(arg: string): string = - if arg == nil: - raise newException(ValueError, "Cannot use nil capture") - else: - return arg +template checkNil(arg: string): string = arg template formatStr*(howExpr, namegetter, idgetter): untyped = let how = howExpr |