initial commit
Some checks failed
sgraves/cpp-build-system_mac/pipeline/head There was a failure building this commit
sgraves/cpp-build-system/pipeline/head There was a failure building this commit

This commit is contained in:
2025-10-17 07:44:16 -05:00
parent 933c973c79
commit 92e3e495ce
1099 changed files with 102722 additions and 0 deletions

36
src/main.cpp Normal file
View File

@@ -0,0 +1,36 @@
#if defined(PROJECT_ENABLE_BACKWARD_CPP)
#include "backward.hpp"
#endif // defined(PROJECT_ENABLE_BACKWARD_CPP)
#include "initialize.hpp"
#include "utils/config.hpp"
#include "utils/error.hpp"
using namespace fifthgrid;
auto main(int argc, char **argv) -> int {
FIFTHGRID_USES_FUNCTION_NAME();
#if defined(PROJECT_ENABLE_BACKWARD_CPP)
static backward::SignalHandling sh;
#endif // defined(PROJECT_ENABLE_BACKWARD_CPP)
if (not fifthgrid::project_initialize()) {
fifthgrid::project_cleanup();
return -1;
}
int exit_code{0};
try {
// TODO Main code here
} catch (const std::exception &e) {
utils::error::handle_exception(function_name, e);
} catch (...) {
utils::error::handle_exception(function_name);
}
fifthgrid::project_cleanup();
return exit_code;
}