diff options
author | Arne Döring <arne.doering@gmx.net> | 2019-05-21 21:31:40 +0200 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2019-05-21 21:31:40 +0200 |
commit | f94ec363abf5b1393014a0bca7202c405512cddd (patch) | |
tree | 54f54dfe076dfa9e70af430521c574517edddb7d /tests/vm | |
parent | 68b5e3e3fe8c4bf314d31d18c147650db99b4f7d (diff) | |
download | Nim-f94ec363abf5b1393014a0bca7202c405512cddd.tar.gz |
Allow void macro result (#11286)
* allow void macro result * add test for void macro result type
Diffstat (limited to 'tests/vm')
-rw-r--r-- | tests/vm/texcl.nim | 2 | ||||
-rw-r--r-- | tests/vm/tstaticprintseq.nim | 4 | ||||
-rw-r--r-- | tests/vm/ttouintconv.nim | 4 |
3 files changed, 5 insertions, 5 deletions
diff --git a/tests/vm/texcl.nim b/tests/vm/texcl.nim index e23a423fe..41975f27b 100644 --- a/tests/vm/texcl.nim +++ b/tests/vm/texcl.nim @@ -18,7 +18,7 @@ proc initOpts(): set[nlOptions] = const cOpts = initOpts() -macro nlo(): typed = +macro nlo() = nlOpts.incl(nloNone) nlOpts.excl(nloDebug) result = newEmptyNode() diff --git a/tests/vm/tstaticprintseq.nim b/tests/vm/tstaticprintseq.nim index 37bf62246..f4aab6b7e 100644 --- a/tests/vm/tstaticprintseq.nim +++ b/tests/vm/tstaticprintseq.nim @@ -24,7 +24,7 @@ bb const s = @[1,2,3] -macro foo: typed = +macro foo() = for e in s: echo e @@ -55,7 +55,7 @@ static: var m2: TData = data for x in m2.numbers: echo x -macro ff(d: static[TData]): typed = +macro ff(d: static[TData]) = for x in d.letters: echo x diff --git a/tests/vm/ttouintconv.nim b/tests/vm/ttouintconv.nim index dd4c597ba..403de8f41 100644 --- a/tests/vm/ttouintconv.nim +++ b/tests/vm/ttouintconv.nim @@ -20,7 +20,7 @@ nimout: ''' #bug #2514 -macro foo(): typed = +macro foo() = var x = 8'u8 var y = 9'u16 var z = 17'u32 @@ -58,7 +58,7 @@ macro foo(): typed = var zz = 0x7FFFFFFF'u32 echo zz -macro foo2(): typed = +macro foo2() = var xx = 0x7FFFFFFFFFFFFFFF echo xx |