net.sourceforge.pmd.lang.ast.TokenMgrError: Lexical error in file C:\Users\Username\Java_programm.jar:myPackage.path/**SampleClass.java at line 1, column 1. Encountered: "\ufeff" (65279), after : ""**

pmd | milch1l | 10 months ago
tip
Do you know that we can give you better hits? Get more relevant results from Samebug’s stack trace search.
  1. 0

    [java] Issue with Byte Order Mark

    pmd | 10 months ago | milch1l
    net.sourceforge.pmd.lang.ast.TokenMgrError: Lexical error in file C:\Users\Username\Java_programm.jar:myPackage.path/**SampleClass.java at line 1, column 1. Encountered: "\ufeff" (65279), after : ""**

    Root Cause Analysis

    1. net.sourceforge.pmd.lang.ast.TokenMgrError

      Lexical error in file C:\Users\Username\Java_programm.jar:myPackage.path/**SampleClass.java at line 1, column 1. Encountered: "\ufeff" (65279), after : ""**

      at net.sourceforge.pmd.lang.java.ast.JavaParserTokenManager.getNextToken()
    2. PMD Java
      AbstractJavaParser.parse
      1. net.sourceforge.pmd.lang.java.ast.JavaParserTokenManager.getNextToken(JavaParserTokenManager.java:2263)
      2. net.sourceforge.pmd.lang.java.ast.JavaParser.<init>(JavaParser.java:10903)
      3. net.sourceforge.pmd.lang.java.AbstractJavaParser.createJavaParser(AbstractJavaParser.java:42)
      4. net.sourceforge.pmd.lang.java.Java18Parser.createJavaParser(Java18Parser.java:23)
      5. net.sourceforge.pmd.lang.java.AbstractJavaParser.parse(AbstractJavaParser.java:56)
      5 frames
    3. PMD
      SourceCodeProcessor.processSourceCode
      1. net.sourceforge.pmd.SourceCodeProcessor.parse(SourceCodeProcessor.java:91)
      2. net.sourceforge.pmd.SourceCodeProcessor.processSource(SourceCodeProcessor.java:138)
      3. net.sourceforge.pmd.SourceCodeProcessor.processSourceCode(SourceCodeProcessor.java:76)
      4. net.sourceforge.pmd.SourceCodeProcessor.processSourceCode(SourceCodeProcessor.java:43)
      4 frames
    4. PMD Core
      PmdRunnable.call
      1. net.sourceforge.pmd.processor.PmdRunnable.call(PmdRunnable.java:79)
      2. net.sourceforge.pmd.processor.PmdRunnable.call(PmdRunnable.java:25)
      2 frames
    5. Java RT
      ThreadPoolExecutor$Worker.run
      1. java.util.concurrent.FutureTask.run(Unknown Source)
      2. java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
      3. java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      3 frames