lucy-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nwelln...@apache.org
Subject [2/5] git commit: Declare 'args_ok' variable in XS
Date Sun, 20 Jul 2014 11:01:52 GMT
Declare 'args_ok' variable in XS


Project: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/commit/19bec9d0
Tree: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/tree/19bec9d0
Diff: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/diff/19bec9d0

Branch: refs/heads/master
Commit: 19bec9d0b4cb71716d5bb7e2a50b9e37d2a9dc10
Parents: 918e37e
Author: Nick Wellnhofer <wellnhofer@aevum.de>
Authored: Sun Jul 20 10:50:14 2014 +0200
Committer: Nick Wellnhofer <wellnhofer@aevum.de>
Committed: Sun Jul 20 10:50:14 2014 +0200

----------------------------------------------------------------------
 compiler/src/CFCPerlConstructor.c | 1 +
 compiler/src/CFCPerlMethod.c      | 1 +
 compiler/src/CFCPerlSub.c         | 2 +-
 3 files changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/19bec9d0/compiler/src/CFCPerlConstructor.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCPerlConstructor.c b/compiler/src/CFCPerlConstructor.c
index 63db008..634b37f 100644
--- a/compiler/src/CFCPerlConstructor.c
+++ b/compiler/src/CFCPerlConstructor.c
@@ -119,6 +119,7 @@ CFCPerlConstructor_xsub_def(CFCPerlConstructor *self) {
         "    dXSARGS;\n"
         "    %s arg_self;\n"
         "%s"
+        "    bool args_ok;\n"
         "    CFISH_UNUSED_VAR(cv);\n"
         "    if (items < 1) { CFISH_THROW(CFISH_ERR, \"Usage: %%s(class_name, ...)\",
 GvNAME(CvGV(cv))); }\n"
         "    SP -= items;\n"

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/19bec9d0/compiler/src/CFCPerlMethod.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCPerlMethod.c b/compiler/src/CFCPerlMethod.c
index a574b93..ca80351 100644
--- a/compiler/src/CFCPerlMethod.c
+++ b/compiler/src/CFCPerlMethod.c
@@ -254,6 +254,7 @@ S_xsub_def_labeled_params(CFCPerlMethod *self) {
         "    dXSARGS;\n"
         "    %s arg_self;\n"
         "%s"
+        "    bool args_ok;\n"
         "    CFISH_UNUSED_VAR(cv);\n"
         "    if (items < 1) { CFISH_THROW(CFISH_ERR, \"Usage: %%s(%s, ...)\",  GvNAME(CvGV(cv)));
}\n"
         "    SP -= items;\n"

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/19bec9d0/compiler/src/CFCPerlSub.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCPerlSub.c b/compiler/src/CFCPerlSub.c
index 48afd34..226d15a 100644
--- a/compiler/src/CFCPerlSub.c
+++ b/compiler/src/CFCPerlSub.c
@@ -239,7 +239,7 @@ CFCPerlSub_build_allot_params(CFCPerlSub *self) {
     // Iterate over args in param list.
     allot_params
         = CFCUtil_cat(allot_params,
-                      "bool args_ok = XSBind_allot_params(\n"
+                      "args_ok = XSBind_allot_params(\n"
                       "        &(ST(0)), 1, items, ", NULL);
     for (size_t i = 1; i < num_vars; i++) {
         CFCVariable *var = arg_vars[i];


Mime
View raw message