-1

How to build YAML parser using tatsu python parser generator? Parsing indent-based language like YAML is difficult, so I cannot achieve this.

Conao3
  • 171
  • 1
  • 3
  • 17
  • This has been asked many times. You should search for previous answers. This is one https://stackoverflow.com/questions/356638/how-would-you-parse-indentation-python-style – Apalala Aug 28 '22 at 12:42
  • Does this answer your question? [How would you parse indentation (python style)?](https://stackoverflow.com/questions/356638/how-would-you-parse-indentation-python-style) – Apalala Aug 28 '22 at 12:43
  • No, I don't want to know generic method, I want to know tatsu specific way. – Conao3 Aug 29 '22 at 00:15
  • How to generate INDENT or DEDENT token using tatsu? it is seems not documented. – Conao3 Aug 29 '22 at 00:16

1 Answers1

0

TatSu was used to do experiments and bootstrap the new PEG parser in Python.

You can find the solutions to INDENT/DEDENT I used in the original efforts here:

https://github.com/neogeny/pygl

Apalala
  • 9,017
  • 3
  • 30
  • 48