Initial commit

This commit is contained in:
2025-03-31 18:05:17 +02:00
commit 336ef95c3f
10 changed files with 197 additions and 0 deletions

24
hello.cpp Normal file
View File

@@ -0,0 +1,24 @@
#include <cstdio>
extern "C" {
#include "haxcc.h"
}
auto main() -> int {
std::printf("Hello, World!\n");
std::printf("begin: %p, end: %p, len: %lu\n", (void*)mod_begin(), (void*)mod_end(), ((long)mod_end() - (long)mod_begin()) / sizeof(mod));
std::printf("\n");
for (auto* it = mod_begin(); it != mod_end(); ++it) {
it->init();
}
std::printf("\n");
std::printf("we're have init everything\n");
std::printf("\n");
for (auto* it = mod_begin(); it != mod_end(); ++it) {
it->done();
}
return 0;
}