diff options
author | James Lynn Wu <jameslynnwu@users.noreply.github.com> | 2020-04-20 15:01:07 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-20 15:01:07 -0400 |
commit | 02db277e2bbc5906c8787f64dc9a743fe3327f90 (patch) | |
tree | d5876428111b5eb2a1d7bebc2d3221fff54cf3b1 | |
parent | a077a2faf3d0420fac0945c88e0628188d2c8674 (diff) | |
download | apitools-02db277e2bbc5906c8787f64dc9a743fe3327f90.tar.gz |
Use == instead of is to compare strings
-rw-r--r-- | apitools/gen/util.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apitools/gen/util.py b/apitools/gen/util.py index 7cf2902..c2955a8 100644 --- a/apitools/gen/util.py +++ b/apitools/gen/util.py @@ -93,7 +93,7 @@ class Names(object): name = re.sub('[^_A-Za-z0-9]', '_', name) if name[0].isdigit(): name = '_%s' % name - while keyword.iskeyword(name) or name is 'exec': + while keyword.iskeyword(name) or name == 'exec': name = '%s_' % name # If we end up with __ as a prefix, we'll run afoul of python # field renaming, so we manually correct for it. |