How to create a parser in erlang

How to create a parser in erlang that will take a well-formed propositional formula and transform it into some internal representation.

A list of available tools for creating a parser in erlang, as well as projects that use them, can be useful.

+4
source share
1 answer

You can use the leex, yecc, spell1, and others.

  • leex : a regular expression-based lexical analyzer generator for Erlang, similar to lex or flex. File lexer contains parts Definition, Rulesas well as Erlang code.

  • yecc: LALR-1 Erlang, yacc. Non-terminals, Terminals, Rules Root-symbols.

  • spell1: LL (1) Erlang LFE, Lisp Erlang.

  • neotoma: - packrat Erlang Parsing (PEG).


, :

  • Efene: Erlang, , . leex yecc Efene.
  • ErlyDTL: Django Erlang, leex yecc Django.
  • Tnesia: , SQL- (TQL), leex yecc.

Slide , .

+6

Source: https://habr.com/ru/post/1622971/


All Articles