Skip to content

Commit 082f45b

Browse files
committed
Fix unknown Target for sugared __cast__() syntax
1 parent 3de6a1d commit 082f45b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/com/laytonsmith/core/MethodScriptCompiler.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1579,7 +1579,7 @@ public static ParseTree compile(TokenStream stream, Environment environment,
15791579
environment.getEnv(CompilerEnvironment.class).addCompilerWarning(fileOptions, warning);
15801580
f = new ParseTree(new CFunction(Compiler.__autoconcat__.NAME, unknown), fileOptions);
15811581
} else {
1582-
f = new ParseTree(new CFunction(Compiler.p.NAME, unknown), fileOptions);
1582+
f = new ParseTree(new CFunction(Compiler.p.NAME, t.getTarget()), fileOptions);
15831583
}
15841584
constructCount.push(new AtomicInteger(0));
15851585
tree.addChild(f);

0 commit comments

Comments
 (0)