QDox
  1. QDox
  2. QDOX-183 Parser Errors when processing jdk-src
  3. QDOX-189

Parser exception due to 'final' before an annotation used as methodparameter

    Details

    • Type: Sub-task Sub-task
    • Status: Resolved Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.10
    • Fix Version/s: 1.11
    • Component/s: Parser
    • Labels:
      None
    • Number of attachments :
      0

      Description

      at com.thoughtworks.qdox.parser.impl.Parser.yyerror(Parser.java:992)
      at com.thoughtworks.qdox.parser.impl.Parser.yyparse(Parser.java:1298)
      at com.thoughtworks.qdox.parser.impl.Parser.parse(Parser.java:973)
      at com.thoughtworks.qdox.JavaDocBuilder.addSource(JavaDocBuilder.java:322)
      at com.thoughtworks.qdox.JavaDocBuilder.addSource(JavaDocBuilder.java:354)
      at com.thoughtworks.qdox.JavaDocBuilder.addSource(JavaDocBuilder.java:350)
      at com.thoughtworks.qdox.JavaDocBuilder$2.visitFile(JavaDocBuilder.java:440)
      at com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:43)
      at com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:34)
      at com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:34)
      at com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:34)
      at com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:34)
      at com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:34)
      at com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:34)
      at com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:34)
      at com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:34)
      at com.thoughtworks.qdox.directorywalker.DirectoryScanner.scan(DirectoryScanner.java:52)
      at com.thoughtworks.qdox.JavaDocBuilder.addSourceTree(JavaDocBuilder.java:437)
      at com.thoughtworks.qdox.JavaDocBuilder.addSourceTree(JavaDocBuilder.java:426)
      at ch.fhnw.i4ds.yadoc.MainTest.main(MainTest.java:44)

        Activity

        Hide
        Marco Soldati added a comment -
        /**
         * final @NotNull localName causes the problem. Remove the final modifier and everything will work correctly.
         */
        public void testFinalAnnotationParam() {
        	JavaDocBuilder builder = new JavaDocBuilder();		
        	String source = "public final class WSEndpointReference {\n" +
        		"    public void writeTo(final @NotNull String localName, @NotNull XMLStreamWriter w) throws XMLStreamException {\n" +
        		"    }\n" +
        		"}";
        	builder.addSource(new StringReader(source));
        }
        
        Show
        Marco Soldati added a comment - /** * final @NotNull localName causes the problem. Remove the final modifier and everything will work correctly. */ public void testFinalAnnotationParam() { JavaDocBuilder builder = new JavaDocBuilder(); String source = " public final class WSEndpointReference {\n" + " public void writeTo( final @NotNull String localName, @NotNull XMLStreamWriter w) throws XMLStreamException {\n" + " }\n" + "}" ; builder.addSource( new StringReader(source)); }
        Robert Scholte made changes -
        Field Original Value New Value
        Summary Exception #4 Parser exception due to 'final' before an annotation used as methodparameter
        Hide
        Robert Scholte added a comment - - edited

        Fixed in rev. 696

        Show
        Robert Scholte added a comment - - edited Fixed in rev. 696
        Robert Scholte made changes -
        Fix Version/s 1.11 [ 16104 ]
        Status Open [ 1 ] Resolved [ 5 ]
        Assignee Robert Scholte [ rfscholte ]
        Resolution Fixed [ 1 ]

          People

          • Assignee:
            Robert Scholte
            Reporter:
            Marco Soldati
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: