Closed f-hy closed 3 months ago
Can I get many programs in only one mpc file? I find that when I give the code:
#fs.mpc from Compiler.compilerLib import Compiler @compiler.register_function('fs0') def fs0(): print_ln("fs0") @compiler.register_function('fs1') def fs1(): print_ln("fs1") @compiler.register_function('fs2') def fs2(): print_ln("fs2")
then I will get only one program named "fs2*" via:
python Programs/Source/fs.mpc
fs0 and fs1 not compiled.
fs0
fs1
You have to run compiler.compile_func() after every call of register_function.
compiler.compile_func()
register_function
Can I get many programs in only one mpc file? I find that when I give the code:
then I will get only one program named "fs2*" via:
fs0
andfs1
not compiled.