Issue 1115 - waf 1.5 update
authorThomas Nagy <tnagy2pow10@gmail.com>
Sat, 18 Feb 2012 00:03:32 +0000 (01:03 +0100)
committerThomas Nagy <tnagy2pow10@gmail.com>
Sat, 18 Feb 2012 00:03:32 +0000 (01:03 +0100)
wafadmin/Tools/preproc.py

index 5055456054b9612d8c28696b6ee50eb8df218d86..6c49326ec3e5945137972c5fab97226291e1118c 100644 (file)
@@ -555,8 +555,7 @@ def parse_char(txt):
                except KeyError: raise PreprocError("could not parse char literal '%s'" % txt)
 
 @Utils.run_once
-def tokenize(s):
-       """convert a string into a list of tokens (shlex.split does not apply to c/c++/d)"""
+def tokenize_private(s):
        ret = []
        for match in re_clexer.finditer(s):
                m = match.group
@@ -591,6 +590,10 @@ def tokenize(s):
                                break
        return ret
 
+def tokenize(s):
+       """convert a string into a list of tokens (shlex.split does not apply to c/c++/d)"""
+       return tokenize_private(s)[:]
+
 @Utils.run_once
 def define_name(line):
        return re_mac.match(line).group(0)