Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NPE using --dot option #1109

Open
bachish opened this issue Jun 25, 2024 · 0 comments
Open

NPE using --dot option #1109

bachish opened this issue Jun 25, 2024 · 0 comments

Comments

@bachish
Copy link

bachish commented Jun 25, 2024

Hi! I see resolved issues with --dot before, but in version 1.8.2 i have same problem.

JFlex creates an empty .dot file and fails with an NPE error.

JFlex file content:

package org.example;
%%

%class Lexer
%unicode
%line
%column
%type String

%%

"a"         { return "a"; }
"b"         { return "b"; }

[^] { System.out.println("Illegal character <" + yytext() + ">"); }

Stack trace:

[user]$ jflex --dot simple.jflex
Reading "simple.jflex"
Constructing NFA : 
Unexpected exception encountered. This indicates a bug in JFlex.
Please consider filing an issue at http://github.com/jflex-de/jflex/issues/new

java.lang.NullPointerException
        at jflex.core.NFA.dotFormat(NFA.java:502)
        at jflex.core.NFA.writeDot(NFA.java:478)
        at jflex.generator.LexGenerator.generate(LexGenerator.java:80)
        at jflex.Main.generate(Main.java:320)
        at jflex.Main.main(Main.java:336)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant