Adding support for windows and fixing some errors
This commit is contained in:
parent
2722a25036
commit
34a8d4eafd
84 changed files with 168 additions and 255 deletions
|
|
@ -5,11 +5,11 @@ file(GLOB SOURCES "./private/*.cpp")
|
|||
file(GLOB HEADERS "./public/*.hpp")
|
||||
add_library(${PROJECT_NAME} STATIC ${SOURCES} ${HEADERS})
|
||||
target_include_directories(${PROJECT_NAME} PUBLIC ./public/)
|
||||
target_link_libraries(${PROJECT_NAME} PUBLIC Utils)
|
||||
target_link_libraries(${PROJECT_NAME} PUBLIC Allocators)
|
||||
|
||||
### -------------------------- Tests -------------------------- ###
|
||||
enable_testing()
|
||||
file(GLOB TEST_SOURCES "./tests/*.cpp")
|
||||
add_executable(${PROJECT_NAME}Tests ${TEST_SOURCES})
|
||||
target_link_libraries(${PROJECT_NAME}Tests ${PROJECT_NAME} Utils)
|
||||
add_test(NAME ${PROJECT_NAME}Tests COMMAND ${PROJECT_NAME}Tests)
|
||||
add_test(NAME ${PROJECT_NAME}Tests COMMAND ${PROJECT_NAME}Tests)
|
||||
|
|
|
|||
|
|
@ -2,10 +2,9 @@
|
|||
/// whoaoao wtf
|
||||
|
||||
#include "MathCommon.hpp"
|
||||
#include "Allocators.hpp"
|
||||
|
||||
#include "ContainersCommon.hpp"
|
||||
|
||||
static tp::ModuleManifest* sModuleDependencies[] = { &tp::gModuleContainers, nullptr };
|
||||
static tp::ModuleManifest* sModuleDependencies[] = { &tp::gModuleAllocators, nullptr };
|
||||
|
||||
tp::ModuleManifest tp::gModuleMath = ModuleManifest("Math", nullptr, nullptr, sModuleDependencies);
|
||||
|
||||
|
|
@ -42,4 +41,4 @@ tp::alnf std_rad(const tp::alnf val) { return val * (PI / 180.f); }
|
|||
tp::alnf std_deg(const tp::alnf val) { return val * (180.f / PI); }
|
||||
tp::alnf std_atan2(const tp::alnf X, const tp::alnf Y) { return atan2((tp::halnf) X, (tp::halnf) Y); }
|
||||
tp::alnf std_atan(const tp::alnf val) { return atan((tp::halnf) val); }
|
||||
tp::alnf std_log2(const tp::alnf val) { return log2((tp::halnf) val); }
|
||||
tp::alnf std_log2(const tp::alnf val) { return log2((tp::halnf) val); }
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
|
||||
#include "Topology.hpp"
|
||||
|
||||
void* operator new(std::size_t, void* in) { return in; }
|
||||
#include "NewPlacement.hpp"
|
||||
|
||||
using namespace tp;
|
||||
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ using namespace tp;
|
|||
|
||||
TEST_DEF(ComplexNumber) {
|
||||
TEST((ComplexCart{ 3, 4 }.mod() == 5));
|
||||
TEST((ComplexCart{ 1, 1 }.arg() == 0.7853981633974483));
|
||||
TEST((abs(ComplexCart{ 1, 1 }.arg() - 0.7853981633974483) < 0.001));
|
||||
TEST((ComplexCart{ 3, 4 }.norm2() == 25));
|
||||
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue