diff --git a/Engine/src/Runtime/Core/Core.h b/Engine/src/Runtime/Core/Core.h index d8339dd..d15bfba 100644 --- a/Engine/src/Runtime/Core/Core.h +++ b/Engine/src/Runtime/Core/Core.h @@ -37,4 +37,25 @@ #error The target system must be defined. (See https://github.com/scorpioblood/PhanesEngine for more information) -#endif // P_WIN_BUILD \ No newline at end of file +#endif // P_WIN_BUILD + + +namespace Phanes +{ + + template + using Ref = std::shared_ptr; + + template + constexpr Ref MakeRef(Args&& ...args) + { + return std::make_shared(std::forward(args)...); + } + + +} + +int test() +{ + +} \ No newline at end of file diff --git a/Engine/src/Runtime/Core/public/Math/Boilerplate.h b/Engine/src/Runtime/Core/public/Math/Boilerplate.h index 8306552..74621e1 100644 --- a/Engine/src/Runtime/Core/public/Math/Boilerplate.h +++ b/Engine/src/Runtime/Core/public/Math/Boilerplate.h @@ -47,10 +47,43 @@ -// Typenames with RealType constrain have to be floating point numbers. -template -concept RealType = std::is_floating_point_v; -// Typenames with IntType constrain have to be integer number. -template -concept IntType = std::is_integral_v; \ No newline at end of file + + +namespace Phanes::Core::Math +{ + + // Typenames with RealType constrain have to be floating point numbers. + template + concept RealType = std::is_floating_point_v; + + // Typenames with IntType constrain have to be integer number. + template + concept IntType = std::is_integral_v; + + + + + + // Alias for shared_ptr + template + using Ref = std::shared_ptr; + + // Alias for make_shared + template + constexpr Ref MakeRef(Args&& ...args) + { + return std::make_shared(std::forward(args)...); + } + + // Alias for unique ptr + template + using Scope = std::unique_ptr; + + // Alias for make_unique + template + constexpr Scope MakeScope(Args&& ...args) + { + return std::make_unique(std::forward(args)...); + } +} \ No newline at end of file