Repository: lucy-clownfish
Updated Branches:
  refs/heads/0.5 6a70a65d0 -> 443645ab6


Fix validation of non-ASCII symbol names

Should fix CLOWNFISH-77 (test failures on Strawberry Perl).


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

Branch: refs/heads/0.5
Commit: 443645ab6b1a4ef43759b7b7f8d079dbe673ec12
Parents: 6a70a65
Author: Nick Wellnhofer <wellnho...@aevum.de>
Authored: Wed Apr 6 16:04:14 2016 +0200
Committer: Nick Wellnhofer <wellnho...@aevum.de>
Committed: Wed Apr 6 16:04:14 2016 +0200

----------------------------------------------------------------------
 compiler/src/CFCSymbol.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/443645ab/compiler/src/CFCSymbol.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCSymbol.c b/compiler/src/CFCSymbol.c
index 2dd7ddc..053c781 100644
--- a/compiler/src/CFCSymbol.c
+++ b/compiler/src/CFCSymbol.c
@@ -56,9 +56,9 @@ S_validate_exposure(const char *exposure) {
 static int
 S_validate_identifier(const char *identifier) {
     const char *ptr = identifier;
-    if (!isalpha(*ptr) && *ptr != '_') { return false; }
+    if (!isalpha((unsigned char)*ptr) && *ptr != '_') { return false; }
     for (; *ptr != 0; ptr++) {
-        if (!isalnum(*ptr) && *ptr != '_') { return false; }
+        if (!isalnum((unsigned char)*ptr) && *ptr != '_') { return false; }
     }
     return true;
 }

Reply via email to