[antlr-interest] ANTLR 3.1 incompatible change for tree parser labels?

Terence Parr parrt at cs.usfca.edu
Wed Mar 25 11:21:05 PDT 2009


ok,  found the bug report:

http://www.antlr.org/jira/browse/ANTLR-314

Let me go see what happened.
Ter
On Mar 25, 2009, at 11:18 AM, Terence Parr wrote:

> Yep, somebody noticed that on the list also. I could swear I've fixed
> that. crap. Did I happen to mention a bug number or URL to you?
> Ter
> On Mar 25, 2009, at 11:09 AM, FranklinChen at cmu.edu wrote:
>
>> Hi,
>>
>> 3.1.3-SNAPSHOT (which I'm pulling in through Maven) seems to have
>> reintroduced this bug!
>>
>>> That is a bug i introduced :(  I have fixed it.  Last daily should
>>> have it.  will go in 3.1.1
>>> Ter
>>> On Aug 25, 2008, at 1:43 PM, FranklinChen at cmu.edu wrote:
>>>
>>>> I am upgrading from ANTLR 3.0 to 3.1, and code that I used to have
>>>> in
>>>> a tree parser no longer works, because of a change to the return
>>>> type
>>>> of labels:
>>>>
>>>> anyWordsAndMedia
>>>>  :
>>>>      list+=anyWord+
>>>>      (
>>>>          list+=url
>>>>          list+=anyWord*
>>>>      )*
>>>>      ->
>>>>      anyWordsAndMedia(list={$list})
>>>>  ;
>>>>
>>>> results in
>>>>
>>>>      List list_list=null;
>>>>      ChatWalker.anyWord_return list = null;
>>>>
>>>> so that the assignment to url fails with
>>>>
>>>> ===
>>>> incompatible types
>>>> found   : org.talkbank.chat.antlr.ChatWalker.url_return
>>>> required: org.talkbank.chat.antlr.ChatWalker.anyWord_return
>>>> ===
>>>>
>>>> What is the correct way for me to do what I'd been doing up till
>>>> now?
>>>>
>>>> -- 
>>>> Franklin
>>>>
>>>> List: http://www.antlr.org/mailman/listinfo/antlr-interest
>>>> Unsubscribe: http://www.antlr.org/mailman/options/antlr-interest/your-email-address
>>>>
>>>
>>>
>>
>> -- 
>> Franklin
>
>
> List: http://www.antlr.org/mailman/listinfo/antlr-interest
> Unsubscribe: http://www.antlr.org/mailman/options/antlr-interest/your-email-address



More information about the antlr-interest mailing list