senseidb/sensei — pull request #24 by sharwell (2014-03-14 02:12:37+00:00)
Title: ANTLR 4 rule versioning

## DO NOT MERGE

As a demonstration of the [rule versioning mechanism](https://github.com/sharwell/antlr4/wiki/Rule-Versioning) I am proposing be included in a future release of ANTLR 4, I created this pull request to demonstrate the use of rule dependency annotations in an actual application.

I am extremely interested in feedback regarding this method of declaring and validating rule dependencies, as described in [the email I sent to the ANTLR mailing list](https://groups.google.com/d/msg/antlr-discussion/l8zyGk1Zi28/B7KSAT8wJd0J).

> Hi everyone,
>
> I am proposing the addition of rule versioning as a new feature in ANTLR 4. Properly used, rule versioning resolves the majority of problems associated with application bugs caused by change to a grammar over time. While I have been using this feature for well over a year, prior to incorporating it into ANTLR 4 we’d like to get feedback regarding the number of users who would actually be using this feature on a regular basis.
>
> I have prepared an overview of this feature, including motivating examples, description on the approach taken to solving this problem and how to make effective use of the feature, and a description of an alternative approach I tried in the past but found it didn’t meet the needs of real applications.
> https://github.com/sharwell/antlr4/wiki/Rule-Versioning
>
> If you are developing an application using ANTLR 4, please take the time to read this page, since this could result in a substantial reduction in your overall development time and long-term maintenance costs. I’m particularly interested in the following feedback:
>
> 1. If rule versioning were included as a feature in ANTLR 4, how likely are you to use it in your application?
> 2. Is the article clear? Which parts did or did not make sense to you?
>
> Thank you,
> Sam Harwell