summary refs log tree commit diff stats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/generics/tgenerictmpl2.nim2
-rw-r--r--tests/macros/tgetimpl.nim15
-rw-r--r--tests/modules/timportas.nim8
3 files changed, 12 insertions, 13 deletions
diff --git a/tests/generics/tgenerictmpl2.nim b/tests/generics/tgenerictmpl2.nim
index ac92d3281..2efb000b3 100644
--- a/tests/generics/tgenerictmpl2.nim
+++ b/tests/generics/tgenerictmpl2.nim
@@ -21,7 +21,7 @@ ttmpl(1)
 ttmpl[int](1) #<- crash case #1
 
 tproc[int]()
-discard tproc[int]
+let _ = tproc[int]
 ttmpl[int]()  #<- crash case #2
 ttmpl[int]    #<- crash case #3
 
diff --git a/tests/macros/tgetimpl.nim b/tests/macros/tgetimpl.nim
index 715c969f3..a546271ff 100644
--- a/tests/macros/tgetimpl.nim
+++ b/tests/macros/tgetimpl.nim
@@ -1,7 +1,7 @@
 discard """
   msg: '''"muhaha"
 proc poo(x, y: int) =
-  let y = x 
+  let y = x
   echo ["poo"]'''
 """
 
@@ -16,14 +16,13 @@ proc poo(x, y: int) =
 
 macro m(x: typed): untyped =
   echo repr x.getImpl
-  result = x
 
-discard m foo
-discard m poo
+m(foo)
+m(poo)
 
 #------------
 
-macro checkOwner(x: typed, check_id: static[int]): untyped = 
+macro checkOwner(x: typed, check_id: static[int]): untyped =
   let sym = case check_id:
     of 0: x
     of 1: x.getImpl.body[0][0][0]
@@ -32,11 +31,11 @@ macro checkOwner(x: typed, check_id: static[int]): untyped =
     else: x
   result = newStrLitNode($sym.owner.symKind)
 
-macro isSameOwner(x, y: typed): untyped = 
-  result = 
+macro isSameOwner(x, y: typed): untyped =
+  result =
     if x.owner == y.owner: bindSym"true"
     else: bindSym"false"
-    
+
 
 static:
   doAssert checkOwner(foo, 0) == "nskModule"
diff --git a/tests/modules/timportas.nim b/tests/modules/timportas.nim
index a92162117..2f7bf7f6a 100644
--- a/tests/modules/timportas.nim
+++ b/tests/modules/timportas.nim
@@ -10,7 +10,7 @@ import times as bar3 except convert
 import definitions as baz
 
 discard foo.v
-discard bar.now
-discard bar2.now
-discard bar3.now
-discard baz.v
\ No newline at end of file
+discard bar.now()
+discard bar2.now()
+discard bar3.now()
+discard baz.v