ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 35581] - ANTLR class and 'extends' cannot span multiple lines
Date Mon, 13 Feb 2006 05:17:33 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=35581>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=35581


kevin.jackson@it.fts-vn.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |WORKSFORME




------- Additional Comments From kevin.jackson@it.fts-vn.com  2006-02-13 06:17 -------
I've just tested this with the following config:
- no CLASSPATH
- antlr-2.7.5.jar
- Ant 1.6.5 - works with line break
- Ant svn trunk - works with line break

both on Java1.6-rc Windows XP SP2

attached build file and test grammar

build.xml
---
<?xml version="1.0"?>
<project name="test-antlr-bug#35581" basedir="." default="run">

  <target name="clean">
    <delete dir="${basedir}/src"/>
    <mkdir dir="${basedir}/src"/>
  </target>
  
  <target name="run" depends="clean">
    <antlr target="test.g" outputdirectory="src">
      <classpath>
        <pathelement location="${basedir}/antlr-2.7.5.jar"/>
      </classpath>	      
    </antlr>
  </target>
</project>

test.g
---

class P extends Parser;

startRule
    :   n:NAME
        {System.out.println("Hi there, "+n.getText());}
    ;

class L 
  extends Lexer; //broken across lines to test ant task

// one-or-more letters followed by a newline
NAME:   ( 'a'..'z'|'A'..'Z' )+ NEWLINE
    ;

NEWLINE
    :   '\r' '\n'   // DOS
    |   '\n'        // UNIX
    ;

As I can't see where in the ANTLR task we could possibly be breaking and causing
this issue, and as it works under test conditions (albeit a simple test), I'm
going to close this - please REOPEN if you can provide a test grammar + build
file where this fails for you - my guess is that this was fixed a long time ago
and was never closed.

Thanks for teh report

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message