diff options
author | ptmcg <ptmcg@austin.rr.com> | 2021-12-18 17:17:19 -0600 |
---|---|---|
committer | ptmcg <ptmcg@austin.rr.com> | 2021-12-18 17:17:19 -0600 |
commit | 5e3e1bbfac8725db8b8c1aee60a098db00a4eeea (patch) | |
tree | 3cf9a3666482e12e9b25085bef8e8733a0cdadaa /pyparsing/core.py | |
parent | 3a12ded223a82c481b75b991e59ed8e8808a945a (diff) | |
download | pyparsing-git-5e3e1bbfac8725db8b8c1aee60a098db00a4eeea.tar.gz |
Fixed PEP-8 compatibility logic in WordStart and WordEnd (Issue #346)
Diffstat (limited to 'pyparsing/core.py')
-rw-r--r-- | pyparsing/core.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pyparsing/core.py b/pyparsing/core.py index c2c8eef..9571499 100644 --- a/pyparsing/core.py +++ b/pyparsing/core.py @@ -3521,7 +3521,7 @@ class WordStart(PositionToken): """ def __init__(self, word_chars: str = printables, *, wordChars: str = printables): - wordChars = word_chars if wordChars != printables else wordChars + wordChars = word_chars if wordChars == printables else wordChars super().__init__() self.wordChars = set(wordChars) self.errmsg = "Not at the start of a word" @@ -3546,7 +3546,7 @@ class WordEnd(PositionToken): """ def __init__(self, word_chars: str = printables, *, wordChars: str = printables): - wordChars = word_chars if wordChars != printables else wordChars + wordChars = word_chars if wordChars == printables else wordChars super().__init__() self.wordChars = set(wordChars) self.skipWhitespace = False |