aboutsummaryrefslogtreecommitdiff
path: root/tomo.c
diff options
context:
space:
mode:
authorBruce Hill <bruce@bruce-hill.com>2024-03-09 18:22:12 -0500
committerBruce Hill <bruce@bruce-hill.com>2024-03-09 18:22:12 -0500
commit2b83ab279dbfb77cfd699d6da944c51c2353e64a (patch)
tree820f23b5c418e9d501a9fecf4fc84d2e26158cb2 /tomo.c
parent1b8f7307a9c9cef191f6277cea5f2d11ef0a5788 (diff)
Add langs to the language
Diffstat (limited to 'tomo.c')
-rw-r--r--tomo.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/tomo.c b/tomo.c
index 1e55c856..631e081f 100644
--- a/tomo.c
+++ b/tomo.c
@@ -66,7 +66,7 @@ int main(int argc, char *argv[])
module_code_t module = compile_file(ast);
- if (verbose) {
+ if (verbose && mode != MODE_RUN) {
FILE *out = popen(heap_strf("%s | bat -P --file-name=%s.h", autofmt, f->filename), "w");
CORD_put(module.header, out);
pclose(out);
@@ -130,6 +130,11 @@ int main(int argc, char *argv[])
"return 0;\n"
"}\n"
);
+ if (verbose) {
+ FILE *out = popen(heap_strf("%s | bat -P --file-name=%s.c", autofmt, f->filename), "w");
+ CORD_put(program, out);
+ pclose(out);
+ }
CORD_put(program, runner);
int status = pclose(runner);