2

I'm trying to use JFlex to write a lexer for YAML, but found it hard, since:

  1. Indentation is sensitive in YAML
  2. There are multiline string like:

    longstr: >
      This is 
      multiline
      line
    

    is hard to implement.

I don't know how to determine and return correct token type for them.

I wander is it good choice to use JFlex? Or do I need some other tool for YAML?

Freewind
  • 193,756
  • 157
  • 432
  • 708
  • I don't know if JFlex is the best choice there is, but I can't think of any reason as to why it would be a bad choice. Indentation and multiline strings wouldn't be that tricky to implement, from what I can imagine. – kabb Apr 20 '14 at 21:22

0 Answers0