woodpyle

Another language grammar parser
Download

woodpyle Ranking & Summary

Advertisement

  • Rating:
  • License:
  • BSD License
  • Price:
  • FREE
  • Publisher Name:
  • Colin Thomas-Arnold
  • Publisher web site:
  • https://github.com/colinta/

woodpyle Tags


woodpyle Description

woodpyle is another language grammar parser, inspired by modgrammar and pyparsing.Developer commentsI needed a language grammar parser for the plywood project, and modgrammar looked like it would be perfect, except I couldn't get the simplest of grammars to work. pyparsing is excellent, but doesn't give me objects back, only lists and strings - I need more than that.I like writing parsers, and I know how I want this one to work, so screw it, I'll do it myself.INSTALLATION pip install woodpyleUSAGEfrom woodpyle import *# basic grammar building blocks:# Word/W, Literal/L, Regex/R# advanced building blocks:# repetition:# ZeroOrMore, OneOrMore, Optional# Any, NextIs, NextIsNot# language building blocks# QuotedString, Number, Integer, Float, Hexadecimal, Octal, Binary# LineComment, BlockComment, Block, IndentedBlock# location# NextIs, PreviousWas, NextIsNot, PreviousWasNot# WordStart, WordEnd, LineStart, LineEnd, StringStart, StringEndProduct's homepage


woodpyle Related Software