Pyparsing

Free and open source Python parsing module
Download

Pyparsing Ranking & Summary

Advertisement

  • Rating:
  • License:
  • MIT License
  • Price:
  • FREE
  • Publisher Name:
  • Paul McGuire
  • Publisher web site:
  • Operating Systems:
  • Mac OS X
  • File Size:
  • 908 KB

Pyparsing Tags


Pyparsing Description

Free and open source Python parsing module The Pyparsing module is an alternative approach to creating and executing simple grammars, vs. the traditional lex/yacc approach, or the use of regular expressions. Pyparsing offers a library of classes that the client code uses to construct the grammar directly in Python code. Requirements: · Python What's New in This Release: · Removed __slots__ declaration on ParseBaseException, for · compatibility with IronPython 2.0.1. Raised by David · Lawler on the pyparsing wiki, thanks David! · Fixed bug in SkipTo/failOn handling - caught by eagle eye · cpennington on the pyparsing wiki! · Fixed second bug in SkipTo when using the ignore constructor · argument, reported by Catherine Devlin, thanks! · Fixed obscure bug reported by Eike Welk when using a class · as a ParseAction with an errant __getitem__ method. · Simplified exception stack traces when reporting parse · exceptions back to caller of parseString or parseFile - thanks · to a tip from Peter Otten on comp.lang.python. · Changed behavior of scanString to avoid infinitely looping on · expressions that match zero-length strings. Prompted by a · question posted by ellisonbg on the wiki. · Enhanced classes that take a list of expressions (And, Or, · MatchFirst, and Each) to accept generator expressions also. · This can be useful when generating lists of alternative · expressions, as in this case, where the user wanted to match · any repetitions of '+', '*', '#', or '.', but not mixtures of them (that is, match '+++', but not '+-+'): · codes = "+*#." · format = MatchFirst(Word(c) for c in codes) · Based on a problem posed by Denis Spir on the Python tutor · list. · Added new example eval_arith.py, which extends the example · simpleArith.py to actually evaluate the parsed expressions.


Pyparsing Related Software