summary refs log tree commit diff stats
path: root/rod
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2011-01-19 00:27:38 +0100
committerAraq <rumpf_a@web.de>2011-01-19 00:27:38 +0100
commit408eb6bbe76e9e1b0651d07467ce2ba9510deb23 (patch)
tree057f23946ca90c77b3be66b04f81618b37d1a82d /rod
parent66cfc851a1aeb9eb8d011a8e0c53b0f8ee83f770 (diff)
downloadNim-408eb6bbe76e9e1b0651d07467ce2ba9510deb23.tar.gz
c2nim: bugfix: less picky about newlines in preprocessor defines
Diffstat (limited to 'rod')
-rwxr-xr-xrod/c2nim/cpp.nim2
-rwxr-xr-xrod/c2nim/tests/systest.c9
2 files changed, 10 insertions, 1 deletions
diff --git a/rod/c2nim/cpp.nim b/rod/c2nim/cpp.nim
index 5507c6116..f59c86044 100755
--- a/rod/c2nim/cpp.nim
+++ b/rod/c2nim/cpp.nim
@@ -16,7 +16,7 @@ proc eatNewLine(p: var TParser, n: PNode) =
   if p.tok.xkind == pxLineComment:
     skipCom(p, n)
     if p.tok.xkind == pxNewLine: getTok(p)
-  else:
+  elif p.tok.xkind == pxNewLine: 
     eat(p, pxNewLine)
   
 proc skipLine(p: var TParser) = 
diff --git a/rod/c2nim/tests/systest.c b/rod/c2nim/tests/systest.c
index 7f689c002..4ba1d9044 100755
--- a/rod/c2nim/tests/systest.c
+++ b/rod/c2nim/tests/systest.c
@@ -9,6 +9,15 @@ extern "C" {
 #  endif
 #endif
 
+typedef void (*callback_t) (int rc);
+
+int   aw_callback_set (AW_CALLBACK c, callback_t callback );
+int   aw_instance_callback_set (AW_CALLBACK c, callback_t callback);
+
+#define AW_BUILD 85 // AW 5.0
+// Limits
+#define AW_MAX_AVCHANGE_PER_SECOND 10
+
 #private expatDll
 
 #if !defined(expatDll)