diff --git a/byterun/include/sm_parser.hpp b/byterun/include/sm_parser.hpp index 2627a6e1a..517669431 100644 --- a/byterun/include/sm_parser.hpp +++ b/byterun/include/sm_parser.hpp @@ -1,6 +1,5 @@ #pragma once -#include #include #include #include diff --git a/byterun/regression_check.sh b/byterun/regression_check.sh index 7ef986b38..68c0a6699 100755 --- a/byterun/regression_check.sh +++ b/byterun/regression_check.sh @@ -1,9 +1,9 @@ #!/usr/bin/env bash -xmake build -cp "build/linux/x86_64/release/byterun" byterun.exe +# xmake build +# cp "build/linux/x86_64/release/byterun" byterun.exe -# dune build > /dev/null +dune build > /dev/null prefix="../regression/" suffix=".lama" diff --git a/byterun/src/compiler.cpp b/byterun/src/compiler.cpp index c86b696b4..7ce0fc93b 100644 --- a/byterun/src/compiler.cpp +++ b/byterun/src/compiler.cpp @@ -1,6 +1,8 @@ // based on src/X86_64.ml +extern "C" { #include "../../runtime/runtime.h" +} #include "compiler.hpp" #include "sm_parser.hpp" @@ -1954,8 +1956,8 @@ std::vector compile(const Options &cmd, Env &env, utils::filter( std::vector{imports}, [](const auto &i) { return i != "Std"; }), - [](const auto &i) -> Instr { - return Call{std::format("init" + i)}; + [](const auto &i) -> Instr { + return Call{std::format("init {}", i)}; }) : std::vector{}), std::move(check_argc_code) ); diff --git a/byterun/src/sm_parser_old.cpp b/byterun/src/sm_parser_old.cpp deleted file mode 100644 index 8b1378917..000000000 --- a/byterun/src/sm_parser_old.cpp +++ /dev/null @@ -1 +0,0 @@ - diff --git a/byterun/xmake.lua b/byterun/xmake.lua index b9e86f1df..3df9ff418 100644 --- a/byterun/xmake.lua +++ b/byterun/xmake.lua @@ -5,9 +5,9 @@ set_languages("c++23", "c23") target("byterun") set_kind("binary") - add_includedirs("include") + add_includedirs("include", "../runtime") add_files("../runtime/**.c", "../runtime/**.S") - add_files("src/**.cpp", "src/**.c") + add_files( "src/**.cpp", "src/**.c") set_warnings("allextra") set_rundir("$(projectdir)") add_defines("WITH_CHECK")