Skip to content

Commit

Permalink
Initial parser generation in CoffeeScript and Perl
Browse files Browse the repository at this point in the history
make -C parser/src/coffeescript test TRACE=1
make -C parser/src/perl test TRACE=1
  • Loading branch information
ingydotnet committed Sep 3, 2020
1 parent 6340d15 commit 61bb3bd
Show file tree
Hide file tree
Showing 19 changed files with 13,096 additions and 1,492 deletions.
6 changes: 3 additions & 3 deletions parser/bin/generate-yaml-grammar
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@ ap.addArgument ['-r', '--rule'],

spec = file_read from

{coffee_generator_class} = require "../lib/generate-yaml-grammar-#{to}"
{generator_class} = require "../lib/generate-yaml-grammar-#{to}"

generator = new coffee_generator_class(spec)
generator = new generator_class(spec)

try
generator.generate_grammar(rule)
generator.gen_grammar(rule)

catch e
file_write '/tmp/yaml-grammar.coffee', generator.grammar
Expand Down
Loading

0 comments on commit 61bb3bd

Please sign in to comment.