File tree Expand file tree Collapse file tree 2 files changed +21
-1
lines changed Expand file tree Collapse file tree 2 files changed +21
-1
lines changed Original file line number Diff line number Diff line change @@ -653,6 +653,10 @@ class BackendUXN : CompilerBackend {
653653 }
654654
655655 override void CompileFuncAddr (FuncAddrNode node) {
656+ foreach (name, word ; words) {
657+ writeln(name);
658+ }
659+
656660 if (node.func ! in words) {
657661 Error(node.error, " Function '%s' doesn't exist" , node.func);
658662 }
Original file line number Diff line number Diff line change @@ -41,14 +41,30 @@ class CodeRemover {
4141 }
4242
4343 if (funcStack.canFind(node.name)) {
44- return ;
44+ continue ;
4545 }
4646
4747 funcStack ~= node.name;
4848 FindFunctions(functions[node.name]);
4949 funcStack = funcStack[0 .. $ - 1 ];
5050 break ;
5151 }
52+ case NodeType.FuncAddr: {
53+ auto node = cast (FuncAddrNode) inode;
54+
55+ if (node.func ! in functions) {
56+ continue ;
57+ }
58+
59+ if (funcStack.canFind(node.func)) {
60+ continue ;
61+ }
62+
63+ funcStack ~= node.func;
64+ FindFunctions(functions[node.func]);
65+ funcStack = funcStack[0 .. $ - 1 ];
66+ break ;
67+ }
5268 case NodeType.If: {
5369 auto node = cast (IfNode) inode;
5470
You can’t perform that action at this time.
0 commit comments