Commit 2d9e5a65 authored by Robert Bradshaw's avatar Robert Bradshaw

Remove spurious const cast and warnings, niceident regex fix, all tests pass.

parent e607ac75
......@@ -1466,7 +1466,7 @@ class DefNode(FuncDefNode):
reqd_kw_flags = []
has_reqd_kwds = False
code.put(
"static const char *%s[] = {" %
"static char *%s[] = {" %
Naming.kwdlist_cname)
for arg in self.args:
if arg.is_generic:
......@@ -1618,8 +1618,7 @@ class DefNode(FuncDefNode):
code.putln('else {')
argformat = '"%s"' % string.join(arg_formats, "")
pt_arglist = [Naming.args_cname, Naming.kwds_cname, argformat,
'(char **)/*temp.hack*/'+Naming.kwdlist_cname] + arg_addrs
pt_arglist = [Naming.args_cname, Naming.kwds_cname, argformat, Naming.kwdlist_cname] + arg_addrs
pt_argstring = string.join(pt_arglist, ", ")
code.putln(
'if (unlikely(!PyArg_ParseTupleAndKeywords(%s))) %s' % (
......
......@@ -17,7 +17,7 @@ import ControlFlow
import __builtin__
possible_identifier = re.compile(ur"(?![0-9])\w+$", re.U).match
nice_identifier = re.compile('[a-zA-Z0-0_]').match
nice_identifier = re.compile('^[a-zA-Z0-0_]+$').match
class Entry:
# A symbol table entry in a Scope or ModuleNamespace.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment