summaryrefslogtreecommitdiff
path: root/pyparsing.py
diff options
context:
space:
mode:
authorptmcg <ptmcg@austin.rr.com>2018-12-28 14:55:39 -0600
committerptmcg <ptmcg@austin.rr.com>2018-12-28 14:55:39 -0600
commitc50c84bac138f176259cf745e628000fd8539330 (patch)
tree5151f3d22bee45609a9824d91c339613ae1cd8f8 /pyparsing.py
parent45b78401e8c224619e1b18b9cf43fc02b196676e (diff)
downloadpyparsing-git-c50c84bac138f176259cf745e628000fd8539330.tar.gz
Fix matching of dictOf with empty contents (Issue #53)
Diffstat (limited to 'pyparsing.py')
-rw-r--r--pyparsing.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/pyparsing.py b/pyparsing.py
index 48e5e23..975846c 100644
--- a/pyparsing.py
+++ b/pyparsing.py
@@ -94,7 +94,7 @@ classes inherit from. Use the docstrings for examples of how to:
"""
__version__ = "2.3.1"
-__versionTime__ = "28 Dec 2018 20:39 UTC"
+__versionTime__ = "28 Dec 2018 20:52 UTC"
__author__ = "Paul McGuire <ptmcg@users.sourceforge.net>"
import string
@@ -5076,7 +5076,7 @@ def dictOf( key, value ):
SQUARE
{'color': 'light blue', 'shape': 'SQUARE', 'posn': 'upper left', 'texture': 'burlap'}
"""
- return Dict( ZeroOrMore( Group ( key + value ) ) )
+ return Dict(OneOrMore(Group(key + value)))
def originalTextFor(expr, asString=True):
"""Helper to return the original, untokenized text for a given