mirror of
https://github.com/ToruNiina/toml11.git
synced 2025-12-16 03:08:52 +08:00
feat: replace detail::stuff by std if possible
This commit is contained in:
@@ -20,12 +20,20 @@
|
||||
namespace toml
|
||||
{
|
||||
|
||||
#if __cplusplus >= 201402L
|
||||
|
||||
using std::make_unique;
|
||||
|
||||
#else
|
||||
|
||||
template<typename T, typename ... Ts>
|
||||
inline std::unique_ptr<T> make_unique(Ts&& ... args)
|
||||
{
|
||||
return std::unique_ptr<T>(new T(std::forward<Ts>(args)...));
|
||||
}
|
||||
|
||||
#endif // __cplusplus >= 2014
|
||||
|
||||
namespace detail
|
||||
{
|
||||
|
||||
|
||||
Reference in New Issue
Block a user