diff options
Diffstat (limited to 'tests/rodfiles')
-rw-r--r-- | tests/rodfiles/aconv.nim | 9 | ||||
-rw-r--r-- | tests/rodfiles/amethods.nim | 13 | ||||
-rw-r--r-- | tests/rodfiles/bconv.nim | 9 | ||||
-rw-r--r-- | tests/rodfiles/bmethods.nim | 29 | ||||
-rw-r--r-- | tests/rodfiles/bmethods2.nim | 29 | ||||
-rw-r--r-- | tests/rodfiles/deada.nim | 8 | ||||
-rw-r--r-- | tests/rodfiles/deada2.nim | 12 | ||||
-rw-r--r-- | tests/rodfiles/deadb.nim | 7 | ||||
-rw-r--r-- | tests/rodfiles/deadg.nim | 10 | ||||
-rwxr-xr-x | tests/rodfiles/gtkex1.nim | 14 | ||||
-rwxr-xr-x | tests/rodfiles/gtkex2.nim | 22 | ||||
-rwxr-xr-x | tests/rodfiles/hallo.nim | 6 | ||||
-rw-r--r-- | tests/rodfiles/hallo2.nim | 17 | ||||
-rw-r--r-- | tests/rodfiles/int2bool.nim | 5 | ||||
-rw-r--r-- | tests/rodfiles/tgeneric1.nim | 13 | ||||
-rw-r--r-- | tests/rodfiles/tgeneric2.nim | 13 |
16 files changed, 0 insertions, 216 deletions
diff --git a/tests/rodfiles/aconv.nim b/tests/rodfiles/aconv.nim deleted file mode 100644 index ffd8f3648..000000000 --- a/tests/rodfiles/aconv.nim +++ /dev/null @@ -1,9 +0,0 @@ -discard """ - output: "ugly conversion successful" -""" - -import int2bool - -if 4: - echo "ugly conversion successful" - diff --git a/tests/rodfiles/amethods.nim b/tests/rodfiles/amethods.nim deleted file mode 100644 index c51d27d24..000000000 --- a/tests/rodfiles/amethods.nim +++ /dev/null @@ -1,13 +0,0 @@ - -type - TBaseClass* = object of TObject - -proc newBaseClass*: ref TBaseClass = - new result - -method echoType*(x: ref TBaseClass) = - echo "base class" - -proc echoAlias*(x: ref TBaseClass) = - echoType x - diff --git a/tests/rodfiles/bconv.nim b/tests/rodfiles/bconv.nim deleted file mode 100644 index 2289a7f97..000000000 --- a/tests/rodfiles/bconv.nim +++ /dev/null @@ -1,9 +0,0 @@ -discard """ - output: "ugly conversion successful 2" -""" - -import int2bool - -if 4: - echo "ugly conversion successful 2" - diff --git a/tests/rodfiles/bmethods.nim b/tests/rodfiles/bmethods.nim deleted file mode 100644 index 995942ad6..000000000 --- a/tests/rodfiles/bmethods.nim +++ /dev/null @@ -1,29 +0,0 @@ -discard """ - output: '''derived class -base class -''' -""" - -import amethods - - -type - TDerivedClass* = object of TBaseClass - -proc newDerivedClass: ref TDerivedClass = - new result - -method echoType*(x: ref TDerivedClass) = - echo "derived class" - -var b, d: ref TBaseClass - -b = newBaseClass() -d = newDerivedClass() - -#b.echoType() -#d.echoType() - -echoAlias d -echoAlias b - diff --git a/tests/rodfiles/bmethods2.nim b/tests/rodfiles/bmethods2.nim deleted file mode 100644 index ac24a2201..000000000 --- a/tests/rodfiles/bmethods2.nim +++ /dev/null @@ -1,29 +0,0 @@ -discard """ - output: '''derived class 2 -base class -''' -""" - -import amethods - - -type - TDerivedClass* = object of TBaseClass - -proc newDerivedClass: ref TDerivedClass = - new result - -method echoType*(x: ref TDerivedClass) = - echo "derived class 2" - -var b, d: ref TBaseClass - -b = newBaseClass() -d = newDerivedClass() - -#b.echoType() -#d.echoType() - -echoAlias d -echoAlias b - diff --git a/tests/rodfiles/deada.nim b/tests/rodfiles/deada.nim deleted file mode 100644 index 3fa4192f8..000000000 --- a/tests/rodfiles/deada.nim +++ /dev/null @@ -1,8 +0,0 @@ -discard """ - output: '''246 -''' -""" - -import deadg, deadb - - diff --git a/tests/rodfiles/deada2.nim b/tests/rodfiles/deada2.nim deleted file mode 100644 index 2925b4d43..000000000 --- a/tests/rodfiles/deada2.nim +++ /dev/null @@ -1,12 +0,0 @@ -discard """ - output: '''246 -xyzabc -''' -""" - -import deadg, deadb - -# now add call to previously unused proc p2: -echo p2("xyz", "abc") - - diff --git a/tests/rodfiles/deadb.nim b/tests/rodfiles/deadb.nim deleted file mode 100644 index 776a07ac7..000000000 --- a/tests/rodfiles/deadb.nim +++ /dev/null @@ -1,7 +0,0 @@ - -import deadg - - -echo p1(123, 123) - - diff --git a/tests/rodfiles/deadg.nim b/tests/rodfiles/deadg.nim deleted file mode 100644 index 97bfbed4f..000000000 --- a/tests/rodfiles/deadg.nim +++ /dev/null @@ -1,10 +0,0 @@ - -{.deadCodeElim: on.} - -proc p1*(x, y: int): int = - result = x + y - -proc p2*(x, y: string): string = - result = x & y - - diff --git a/tests/rodfiles/gtkex1.nim b/tests/rodfiles/gtkex1.nim deleted file mode 100755 index 8f4db4a40..000000000 --- a/tests/rodfiles/gtkex1.nim +++ /dev/null @@ -1,14 +0,0 @@ -import - cairo, glib2, gtk2 - -proc destroy(widget: pWidget, data: pgpointer) {.cdecl.} = - main_quit() - -var - window: pWidget -nimrod_init() -window = window_new(WINDOW_TOPLEVEL) -discard signal_connect(window, "destroy", - SIGNAL_FUNC(gtkex1.destroy), nil) -show(window) -main() diff --git a/tests/rodfiles/gtkex2.nim b/tests/rodfiles/gtkex2.nim deleted file mode 100755 index 3d181ba12..000000000 --- a/tests/rodfiles/gtkex2.nim +++ /dev/null @@ -1,22 +0,0 @@ - -import - glib2, gtk2 - -proc destroy(widget: pWidget, data: pgpointer){.cdecl.} = - main_quit() - -var - window: PWidget - button: PWidget - -nimrod_init() -window = window_new(WINDOW_TOPLEVEL) -button = button_new("Click me") -set_border_width(PContainer(Window), 5) -add(PContainer(window), button) -discard signal_connect(window, "destroy", - SIGNAL_FUNC(gtkex2.destroy), nil) -show(button) -show(window) -main() - diff --git a/tests/rodfiles/hallo.nim b/tests/rodfiles/hallo.nim deleted file mode 100755 index ac45be9fa..000000000 --- a/tests/rodfiles/hallo.nim +++ /dev/null @@ -1,6 +0,0 @@ -discard """ - output: "Hello World" -""" - -echo "Hello World" - diff --git a/tests/rodfiles/hallo2.nim b/tests/rodfiles/hallo2.nim deleted file mode 100644 index a4b3957ec..000000000 --- a/tests/rodfiles/hallo2.nim +++ /dev/null @@ -1,17 +0,0 @@ -discard """ - output: "Hello World" -""" - -# Test incremental type information - -type - TNode = object {.pure.} - le, ri: ref TNode - data: string - -proc newNode(data: string): ref TNode = - new(result) - result.data = data - -echo newNode("Hello World").data - diff --git a/tests/rodfiles/int2bool.nim b/tests/rodfiles/int2bool.nim deleted file mode 100644 index e6add9848..000000000 --- a/tests/rodfiles/int2bool.nim +++ /dev/null @@ -1,5 +0,0 @@ - -converter uglyToBool*(x: int): bool = - result = x != 0 - - diff --git a/tests/rodfiles/tgeneric1.nim b/tests/rodfiles/tgeneric1.nim deleted file mode 100644 index a3f7b870b..000000000 --- a/tests/rodfiles/tgeneric1.nim +++ /dev/null @@ -1,13 +0,0 @@ -discard """ - output: "abcd" -""" - -import tables - -var x = initTable[int, string]() - -x[2] = "ab" -x[5] = "cd" - -echo x[2], x[5] - diff --git a/tests/rodfiles/tgeneric2.nim b/tests/rodfiles/tgeneric2.nim deleted file mode 100644 index 552d60267..000000000 --- a/tests/rodfiles/tgeneric2.nim +++ /dev/null @@ -1,13 +0,0 @@ -discard """ - output: "abef" -""" - -import tables - -var x = initTable[int, string]() - -x[2] = "ab" -x[5] = "ef" - -echo x[2], x[5] - |