summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorptmcg <ptmcg@9bf210a0-9d2d-494c-87cf-cfb32e7dff7b>2016-08-07 06:19:10 +0000
committerptmcg <ptmcg@9bf210a0-9d2d-494c-87cf-cfb32e7dff7b>2016-08-07 06:19:10 +0000
commitaf7340385096f5bc184925066f02db450e35a5e8 (patch)
tree59229708af8ea3f9998ceeb515f172c4cd50ee99
parent5523612f06244bab438648aeec599e5d683b1b8d (diff)
downloadpyparsing-af7340385096f5bc184925066f02db450e35a5e8.tar.gz
docstring tweak (ParseResults.asDict)
git-svn-id: svn://svn.code.sf.net/p/pyparsing/code/trunk@398 9bf210a0-9d2d-494c-87cf-cfb32e7dff7b
-rw-r--r--src/pyparsing.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/pyparsing.py b/src/pyparsing.py
index 0c6f384..0d982e5 100644
--- a/src/pyparsing.py
+++ b/src/pyparsing.py
@@ -697,8 +697,8 @@ class ParseResults(object):
# even though a ParseResults supports dict-like access, sometime you just need to have a dict
import json
- print(json.dumps(result_dict)) # -> {"month": "31", "day": "1999", "year": "12"}
print(json.dumps(result)) # -> Exception: TypeError: ... is not JSON serializable
+ print(json.dumps(result.asDict())) # -> {"month": "31", "day": "1999", "year": "12"}
"""
if PY_3:
item_fn = self.items