This commit is contained in:
2 files changed
+9
-2
No files matched your search
+6
-1
@@ -5,7 +5,12 @@ project(Arbutils)
|
||||
add_compile_options(-Wall -Wextra -Werror)
|
||||
# We like new stuff, so set the c++ standard to c++20.
|
||||
set(CMAKE_CXX_STANDARD 20)
|
||||
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
|
||||
|
||||
if (NOT WINDOWS)
|
||||
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
|
||||
else()
|
||||
set(CMAKE_POSITION_INDEPENDENT_CODE OFF)
|
||||
endif()
|
||||
|
||||
option(WINDOWS "Whether the build target is Windows or not." OFF)
|
||||
option(SHARED "Whether we should build a shared library, instead of a static one." OFF)
|
||||
|
||||
+3
-1
@@ -152,9 +152,11 @@ static consteval const char* file_name(const char* path) {
|
||||
}
|
||||
|
||||
#define THROW(message) \
|
||||
{ \
|
||||
std::stringstream ___ss; \
|
||||
___ss << "[" << file_name(__FILE__) << ":" << __LINE__ << "] " << message; \
|
||||
throw ArbUt::Exception(___ss.str());
|
||||
throw ArbUt::Exception(___ss.str()); \
|
||||
}
|
||||
|
||||
#define NOT_REACHABLE THROW("Not reachable");
|
||||
#define NOT_IMPLEMENTED THROW("Not implemented");
|
||||
|
||||
Reference in new issue
Block a user