[ragel-users] setting the initial state
thurston at complang.org
Thu Apr 7 14:20:30 PDT 2011
I can't say when it will be done, but I can give you an issue number :)
On 04/06/2011 08:43 PM, Nate wrote:
> Hi Adrian and friends,
> I need to re-parse some input, starting at an offset and an initial
> state. I know I can just set "p" to the offset and "cs" to the state,
> however, my states are meaningful outside of the parser. My program is a
> language parser for syntax highlighting, so I need int constants that
> represent the type of tokens founds. I need some way of saying, "parse
> this char at offset X using initial token type LITERAL_CHAR". I don't
> care if the LITERAL_CHAR constant is the same as the parser state, but I
> need some way of setting "cs" to a specific machine name or label.
> I came across a post on the mailing list from 2007 saying, "For a really
> long time now I've been meaning to implement a new feature which should
> help you out. %% write entry <machine_or_label>;". This would work
> nicely I think. I guess it has been a *really* really long time now, eh?
> :D Is there any chance that this feature could be implemented soonly?
> Ragel is so awesome! :)
> ragel-users mailing list
> ragel-users at complang.org
Adrian D. Thurston
More information about the ragel-users