diff options
author | Martin v. Löwis <martin@v.loewis.de> | 2007-10-29 19:54:24 (GMT) |
---|---|---|
committer | Martin v. Löwis <martin@v.loewis.de> | 2007-10-29 19:54:24 (GMT) |
commit | 2673a5723433ff398fed901a8ebebb265031091e (patch) | |
tree | e07044a5cf7dc6c2068a715a04de9f4b88878607 | |
parent | 6203d8fa11eeabac83e908687cc03c1c001a3f8a (diff) | |
download | cpython-2673a5723433ff398fed901a8ebebb265031091e.zip cpython-2673a5723433ff398fed901a8ebebb265031091e.tar.gz cpython-2673a5723433ff398fed901a8ebebb265031091e.tar.bz2 |
Bug #1356: Avoid using the C99 keyword 'restrict'.
-rw-r--r-- | Python/symtable.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Python/symtable.c b/Python/symtable.c index 83e571e..968fe25 100644 --- a/Python/symtable.c +++ b/Python/symtable.c @@ -465,12 +465,12 @@ analyze_name(PySTEntryObject *ste, PyObject *scopes, PyObject *name, long flags, Note that the current block's free variables are included in free. That's safe because no name can be free and local in the same scope. - The 'restrict' argument may be set to a string to restrict the analysis + The 'restricted' argument may be set to a string to restrict the analysis to the one variable whose name equals that string (e.g. "__class__"). */ static int -analyze_cells(PyObject *scopes, PyObject *free, const char *restrict) +analyze_cells(PyObject *scopes, PyObject *free, const char *restricted) { PyObject *name, *v, *v_cell; int success = 0; @@ -487,8 +487,8 @@ analyze_cells(PyObject *scopes, PyObject *free, const char *restrict) continue; if (!PySet_Contains(free, name)) continue; - if (restrict != NULL && - PyUnicode_CompareWithASCIIString(name, restrict)) + if (restricted != NULL && + PyUnicode_CompareWithASCIIString(name, restricted)) continue; /* Replace LOCAL with CELL for this name, and remove from free. It is safe to replace the value of name |