summaryrefslogtreecommitdiff
path: root/examples/statemachine
diff options
context:
space:
mode:
authorPaul McGuire <ptmcg@austin.rr.com>2019-05-27 21:09:48 -0500
committerPaul McGuire <ptmcg@austin.rr.com>2019-05-27 21:09:48 -0500
commitfa1482d7c39de6d5ff534eebff7e76de7acfef10 (patch)
treeb1515860e4d818f33ce9929193aa8d4187b19beb /examples/statemachine
parentde5633bc975aad61d28ade5f96bf4af854657a6a (diff)
downloadpyparsing-git-fa1482d7c39de6d5ff534eebff7e76de7acfef10.tar.gz
Typo - `isinstance` should be `issubclass`
Diffstat (limited to 'examples/statemachine')
-rw-r--r--examples/statemachine/statemachine.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/statemachine/statemachine.py b/examples/statemachine/statemachine.py
index 398faa3..4f1f31c 100644
--- a/examples/statemachine/statemachine.py
+++ b/examples/statemachine/statemachine.py
@@ -90,7 +90,7 @@ def expand_state_definition(source, loc, tokens):
" self._state = None",
" def initialize_state(self, init_state):",
- " if isinstance(init_state, {baseStateClass}):".format(baseStateClass=baseStateClass),
+ " if issubclass(init_state, {baseStateClass}):".format(baseStateClass=baseStateClass),
" init_state = init_state()",
" self._state = init_state",