From: Martin Pitt Date: Wed, 30 Nov 2016 08:20:15 +0000 (+0100) Subject: parse_hwdb: fix to work with pyparsing 2.1.10 X-Git-Tag: v234~775^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f644a6da7a6f11d20116842e2ce1c7e9c0b0ad64;p=platform%2Fupstream%2Fsystemd.git parse_hwdb: fix to work with pyparsing 2.1.10 pyparsing 2.1.10 fixed the handling of LineStart to really just apply to line starts and not ignore whitespace and comments any more. Adjust EMPTYLINE to this. Many thanks to Paul McGuire for pointing this out! --- diff --git a/hwdb/parse_hwdb.py b/hwdb/parse_hwdb.py index 5d4c5ea..5856d12 100755 --- a/hwdb/parse_hwdb.py +++ b/hwdb/parse_hwdb.py @@ -56,7 +56,7 @@ except ImportError: lru_cache = lambda: (lambda f: f) EOL = LineEnd().suppress() -EMPTYLINE = LineStart() + LineEnd() +EMPTYLINE = LineEnd() COMMENTLINE = pythonStyleComment + EOL INTEGER = Word(nums) REAL = Combine((INTEGER + Optional('.' + Optional(INTEGER))) ^ ('.' + INTEGER))