mirror of
https://github.com/python/cpython.git
synced 2025-11-02 19:12:55 +00:00
Reduce scope of feature
This commit is contained in:
parent
c1f213ebdc
commit
b15ec09343
1 changed files with 1 additions and 2 deletions
|
|
@ -13,7 +13,6 @@ static int
|
||||||
future_check_features(PyFutureFeatures *ff, stmt_ty s, const char *filename)
|
future_check_features(PyFutureFeatures *ff, stmt_ty s, const char *filename)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
const char *feature;
|
|
||||||
asdl_seq *names;
|
asdl_seq *names;
|
||||||
|
|
||||||
assert(s->kind == ImportFrom_kind);
|
assert(s->kind == ImportFrom_kind);
|
||||||
|
|
@ -21,7 +20,7 @@ future_check_features(PyFutureFeatures *ff, stmt_ty s, const char *filename)
|
||||||
names = s->v.ImportFrom.names;
|
names = s->v.ImportFrom.names;
|
||||||
for (i = 0; i < asdl_seq_LEN(names); i++) {
|
for (i = 0; i < asdl_seq_LEN(names); i++) {
|
||||||
alias_ty name = asdl_seq_GET(names, i);
|
alias_ty name = asdl_seq_GET(names, i);
|
||||||
feature = PyString_AsString(name->name);
|
const char *feature = PyString_AsString(name->name);
|
||||||
if (!feature)
|
if (!feature)
|
||||||
return 0;
|
return 0;
|
||||||
if (strcmp(feature, FUTURE_NESTED_SCOPES) == 0) {
|
if (strcmp(feature, FUTURE_NESTED_SCOPES) == 0) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue