✓ Accepted answer
I'm not too familiar with the precise details when it comes to creating a custom parser due to a lack of necessity for one, but I do believe some important components of such would be the "grammar" of it in a sense, or to be specific, context-sensitive grammar. Additionally, abstract-syntax trees might be another valuable concept one can try for using for it, but I don't believe they'd be that useful regarding it.
My best advice for this is just to look at the standard lua implementation of how they set up their grammar in lua 5.1: http://www.lua.org/manual/5.1/manual.html#2.5.6
If I've butchered this in any way, or if I got some things incorrect(like stating whether it's context-sensitive instead of context-free) then please let me know in the comments below.
1 comment
alright thanks, i've set my parser with a keyword detection and then try to parse it with a given string. by the way, i was wanting to make one since i thought it may be fun to create one. thanks