MCPcopy Create free account
hub / github.com/MegEngine/MegCC / AutoFile

Class AutoFile

compiler/lib/KernelGen/Jit/JitExe.cpp:52–61  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

50}
51
52struct AutoFile {
53 std::string file_path = "/tmp/libtcc1.a";
54 AutoFile() {
55 std::ofstream lib;
56 lib.open(file_path, std::ofstream::binary);
57 lib.write(reinterpret_cast<const char*>(libtcc1_a), libtcc1_a_len);
58 lib.close();
59 }
60 ~AutoFile() { std::remove(file_path.c_str()); }
61};
62
63} // namespace
64using namespace megcc;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected