-
Notifications
You must be signed in to change notification settings - Fork 45
Description
We tried a less compilation with an imported file and received a com.github.sommeri.less4j.core.problems.BugHappened while running it. The test case is very simple. In the less file we want to compile we start with a @import "anotherLessFile";
In the imported file we have some correct regular css code (can actually be an empty file) and there does not need to be any other content in the main less file.
This was tested on the standalone version of less4j 0.0.8, java version 1.7.0_10.
We get the following output:
Exception in thread "main" com.github.sommeri.less4j.core.problems.BugHappened: Bug, please report issue: Unexpected token type: 47(IMPORT_SYM) for @import
Offending place: 1:1
at com.github.sommeri.less4j.core.parser.TokenTypeSwitch.switchOn(TokenTypeSwitch.java:132)
at com.github.sommeri.less4j.core.parser.ASTBuilderSwitch.handleStyleSheet(ASTBuilderSwitch.java:94)
at com.github.sommeri.less4j.core.parser.ASTBuilderSwitch.handleStyleSheet(ASTBuilderSwitch.java:68)
at com.github.sommeri.less4j.core.parser.TokenTypeSwitch.switchOn(TokenTypeSwitch.java:37)
at com.github.sommeri.less4j.core.parser.ASTBuilder.parse(ASTBuilder.java:24)
at com.github.sommeri.less4j.core.ThreadUnsafeLessCompiler.doCompile(ThreadUnsafeLessCompiler.java:40)
at com.github.sommeri.less4j.core.ThreadUnsafeLessCompiler.compile(ThreadUnsafeLessCompiler.java:25)
at com.github.sommeri.less4j.core.DefaultLessCompiler.compile(DefaultLessCompiler.java:11)
at com.github.sommeri.less4j.commandline.CommandLine.compile(CommandLine.java:186)
at com.github.sommeri.less4j.commandline.CommandLine.runAsSinglemode(CommandLine.java:80)
at com.github.sommeri.less4j.commandline.CommandLine.realMain(CommandLine.java:68)
at com.github.sommeri.less4j.commandline.CommandLine.main(CommandLine.java:32)