Hi! Thank you very much for this wonderful project.
Is it currently possible to programmatically compile a string representing a snippet of zig code into executable code?
Something that can be written in the code below instead of the ???? to allow the compilation of the given source.
const compile = ????
const program_source =
\\const std = @import("std");
\\
\\pub fn main() anyerror!void {
\\ std.log.info("All your codebase are belong to us.", .{});
\\}
;
const compiled_program = compile(program_source);
My aim is to write a metacompiler and the ability to delegate the compilation to machine code to zig would be great!
Hi! Thank you very much for this wonderful project.
Is it currently possible to programmatically compile a string representing a snippet of zig code into executable code?
Something that can be written in the code below instead of the
????to allow the compilation of the given source.My aim is to write a metacompiler and the ability to delegate the compilation to machine code to zig would be great!