From 9c753b3dc2b465496a94d7ccffc3c9438c3ce325 Mon Sep 17 00:00:00 2001 From: Yuhanun Citgez Date: Wed, 5 Feb 2020 23:39:18 +0100 Subject: [PATCH] src: modernized unique_ptr construction PR-URL: https://github.com/nodejs/node/pull/31654 Reviewed-By: Anna Henningsen Reviewed-By: Colin Ihrig Reviewed-By: James M Snell Reviewed-By: Gus Caplan Reviewed-By: David Carlier Reviewed-By: Franziska Hinkelmann Reviewed-By: Tiancheng "Timothy" Gu --- src/debug_utils.cc | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/debug_utils.cc b/src/debug_utils.cc index 984c04eb2d381d..4553b642b65837 100644 --- a/src/debug_utils.cc +++ b/src/debug_utils.cc @@ -100,16 +100,14 @@ class PosixSymbolDebuggingContext final : public NativeSymbolDebuggingContext { std::unique_ptr NativeSymbolDebuggingContext::New() { - return std::unique_ptr( - new PosixSymbolDebuggingContext()); + return std::make_unique(); } #else // HAVE_EXECINFO_H std::unique_ptr NativeSymbolDebuggingContext::New() { - return std::unique_ptr( - new NativeSymbolDebuggingContext()); + return std::make_unique(); } #endif // HAVE_EXECINFO_H