commit 41b86ae8d92d07587308f68c56b2f4722bc833c5
parent eac08ff414d53e4d57739661f1ba9f94fc2e4f22
Author: Tomas Hlavaty <tom@logand.com>
Date: Sun, 18 Mar 2012 18:12:52 +0100
walk2_fn child arg added
Diffstat:
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/unoidl2.c b/unoidl2.c
@@ -353,7 +353,7 @@ Any build2(Any x) {
return x;
}
-void (*walk2_fn)(Any x, Any k, Any p, Any v);
+void (*walk2_fn)(Any x, Any c, Any k, Any p, Any v);
Any walk2(Any x) {
Any c = cdr(x);
@@ -366,7 +366,7 @@ Any walk2(Any x) {
} else if(MODULE == kind(v)) {
mapc(walk2, c);
} else if(NIL == c) {
- walk2_fn(x, k, p, v);
+ walk2_fn(x, c, k, p, v);
} else {
printf("@@@ walk2 error: unexpected children\n");
print(x);
diff --git a/unoidl2ast.c b/unoidl2ast.c
@@ -28,7 +28,7 @@ extern const Any ast;
extern const Any root2;
static Any pr1(Any x) {print(x); printf("\n\n");}
-static void cell2ast(Any x, Any k, Any p, Any v) {pr1(v);}
+static void cell2ast(Any x, Any c, Any k, Any p, Any v) {pr1(v);}
int main() {
init();