summary refs log tree commit diff stats
path: root/tests/accept/compile
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2011-05-01 20:11:55 +0200
committerAraq <rumpf_a@web.de>2011-05-01 20:11:55 +0200
commit6ff8752be53b7c0ad2c01615fdf1ab1bb619fb83 (patch)
tree6ad172b70b3b54063bc0dd6566a6c4ed0f5b0a99 /tests/accept/compile
parent0d75723f919931c8523715dbd537d6f86d8ac3dd (diff)
downloadNim-6ff8752be53b7c0ad2c01615fdf1ab1bb619fb83.tar.gz
cleaned up the tests; fixes #30; fixes #26
Diffstat (limited to 'tests/accept/compile')
-rw-r--r--tests/accept/compile/tcan_alias_specialised_generic.nim4
-rwxr-xr-xtests/accept/compile/tconsteval.nim4
-rwxr-xr-xtests/accept/compile/tdictdestruct.nim3
-rw-r--r--tests/accept/compile/tgenericmatcher.nim3
-rw-r--r--tests/accept/compile/tgenericrefs.nim4
-rwxr-xr-xtests/accept/compile/tlexer.nim4
-rwxr-xr-xtests/accept/compile/tmodulealias.nim4
-rwxr-xr-xtests/accept/compile/toop.nim3
-rwxr-xr-xtests/accept/compile/trectuple.nim4
-rwxr-xr-xtests/accept/compile/tsortdev.nim3
-rwxr-xr-xtests/accept/compile/tstrtabs.nim2
-rwxr-xr-xtests/accept/compile/ttempl3.nim16
12 files changed, 52 insertions, 2 deletions
diff --git a/tests/accept/compile/tcan_alias_specialised_generic.nim b/tests/accept/compile/tcan_alias_specialised_generic.nim
index 9e93e7266..a8f1972c8 100644
--- a/tests/accept/compile/tcan_alias_specialised_generic.nim
+++ b/tests/accept/compile/tcan_alias_specialised_generic.nim
@@ -1,3 +1,7 @@
+discard """
+  disabled: true
+"""
+
 ##
 ## can_alias_specialised_generic Nimrod Module
 ##
diff --git a/tests/accept/compile/tconsteval.nim b/tests/accept/compile/tconsteval.nim
index ce90d7c27..10af9ad35 100755
--- a/tests/accept/compile/tconsteval.nim
+++ b/tests/accept/compile/tconsteval.nim
@@ -1,3 +1,7 @@
+discard """
+  disabled: true
+"""
+
 import strutils
 
 const
diff --git a/tests/accept/compile/tdictdestruct.nim b/tests/accept/compile/tdictdestruct.nim
index 8d828aaf7..9c1f27ed8 100755
--- a/tests/accept/compile/tdictdestruct.nim
+++ b/tests/accept/compile/tdictdestruct.nim
@@ -1,3 +1,6 @@
+discard """
+  disabled: true
+"""
 
 type
   TDict[TK, TV] = object
diff --git a/tests/accept/compile/tgenericmatcher.nim b/tests/accept/compile/tgenericmatcher.nim
index eaf3da67c..6ff0dd505 100644
--- a/tests/accept/compile/tgenericmatcher.nim
+++ b/tests/accept/compile/tgenericmatcher.nim
@@ -1,3 +1,6 @@
+discard """
+  disabled: true
+"""
 
 type
   TMatcherKind = enum
diff --git a/tests/accept/compile/tgenericrefs.nim b/tests/accept/compile/tgenericrefs.nim
index b0e77cef5..2a3de7edd 100644
--- a/tests/accept/compile/tgenericrefs.nim
+++ b/tests/accept/compile/tgenericrefs.nim
@@ -1,3 +1,7 @@
+discard """
+  disabled: true
+"""
+
 # Compiles:
 
 type 
diff --git a/tests/accept/compile/tlexer.nim b/tests/accept/compile/tlexer.nim
index 968a10bdf..10a8ab51d 100755
--- a/tests/accept/compile/tlexer.nim
+++ b/tests/accept/compile/tlexer.nim
@@ -1,3 +1,7 @@
+discard """

+  disabled: true

+"""

+

 # We start with a comment

 # This is the same comment

 

diff --git a/tests/accept/compile/tmodulealias.nim b/tests/accept/compile/tmodulealias.nim
index 1154cb99d..a7d155e51 100755
--- a/tests/accept/compile/tmodulealias.nim
+++ b/tests/accept/compile/tmodulealias.nim
@@ -1,4 +1,6 @@
-
+discard """
+  disabled: true
+"""
 
 when defined(windows):
   import winlean
diff --git a/tests/accept/compile/toop.nim b/tests/accept/compile/toop.nim
index d103c6304..db6d9e595 100755
--- a/tests/accept/compile/toop.nim
+++ b/tests/accept/compile/toop.nim
@@ -1,3 +1,6 @@
+discard """
+  disabled: true
+"""
 
 type
   TA = object
diff --git a/tests/accept/compile/trectuple.nim b/tests/accept/compile/trectuple.nim
index c9ac45797..f60fe2841 100755
--- a/tests/accept/compile/trectuple.nim
+++ b/tests/accept/compile/trectuple.nim
@@ -1,3 +1,7 @@
+discard """
+  disabled: true
+"""
+
 type
     PNode = ref TNode
     TNode = tuple[self: PNode]
diff --git a/tests/accept/compile/tsortdev.nim b/tests/accept/compile/tsortdev.nim
index 1246d7581..c4e63fab4 100755
--- a/tests/accept/compile/tsortdev.nim
+++ b/tests/accept/compile/tsortdev.nim
@@ -1,3 +1,6 @@
+discard """
+  disabled: true
+"""
 
 import math, algorithm
 
diff --git a/tests/accept/compile/tstrtabs.nim b/tests/accept/compile/tstrtabs.nim
index 299db609d..251ec77ef 100755
--- a/tests/accept/compile/tstrtabs.nim
+++ b/tests/accept/compile/tstrtabs.nim
@@ -1,6 +1,6 @@
 import strtabs
 
-var tab = newStringTable(["key1", "val1", "key2", "val2"], 
+var tab = newStringTable({"key1": "val1", "key2": "val2"}, 
                          modeStyleInsensitive)
 for i in 0..80:
   tab["key_" & $i] = "value" & $i
diff --git a/tests/accept/compile/ttempl3.nim b/tests/accept/compile/ttempl3.nim
index 0c8fa9a94..7b2c70f79 100755
--- a/tests/accept/compile/ttempl3.nim
+++ b/tests/accept/compile/ttempl3.nim
@@ -24,3 +24,19 @@ var
 ha = 1  
 echo(ha)
 
+
+# Test identifier generation:
+template prefix(name: expr): expr = `"hu" name`
+
+var `hu "XYZ"` = "yay"
+
+echo prefix(XYZ)
+
+template typedef(name: expr, typ: typeDesc) = 
+  type
+    `T name`* = typ
+    `P name`* = ref `T name`
+    
+typedef(myint, int)
+var x: PMyInt
+