Hello,

Since autocompletion is not yet supported by ANTLR 
(http://groups.google.com/group/il-antlr-interest/browse_thread/thread/7c6d05a35046854d),
 I am thinking of implementing this simple reverse engineering approach.

1. Take a programm, which is complete in terms of the grammar.
2. Parse it in antlr parser.
3. During parsing of this "complete program", every current token type will get 
a set of token types, which can follow this current token.
4. As user types his program, the latter will be parsed on every key stroke 
(incrementally or not), and a current token will be extracted, which then will 
be used to get a corresponding set of possible predictions.
5. Optionally, the predictions will be filtered by their semantic validity, 
before presented to the user.

Am I overlooking something obvious feature of ANTLR, which could simplify this 
procedure? Specifically, are items 1 to 3 above the best way to obtain the raw 
predictions for every token type?

Thanks.

V

List: http://www.antlr.org:8080/mailman/listinfo/antlr-interest
Unsubscribe: 
http://www.antlr.org:8080/mailman/options/antlr-interest/your-email-address


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"il-antlr-interest" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/il-antlr-interest?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to