Create an executable for a program in an interpreted language: Difference between revisions

Content added Content deleted
(julia example)
 
Line 407: Line 407:
using StaticCompiler, StaticTools
using StaticCompiler, StaticTools


hello() = println(c"Hello world!") # the c"" hsyntax defines static C type string
hello() = println(c"Hello world!") # the c"" syntax defines a static C type string
compile_executable(hello, (), "./") # can now run this as executable "hello"
compile_executable(hello, (), "./") # can now run this as executable "hello"
</syntaxhighlight>{{out}}
</syntaxhighlight>{{out}}