From 7bace89de0d2a3b9f51d07fbf0e48ee196364c97 Mon Sep 17 00:00:00 2001 From: Anna Henningsen Date: Tue, 1 Oct 2019 21:58:12 +0200 Subject: [PATCH] src: allow unique_ptrs with custom deleter in memory tracker PR-URL: https://github.com/nodejs/quic/pull/145 Reviewed-By: James M Snell --- src/memory_tracker-inl.h | 10 ---------- src/memory_tracker.h | 5 ----- 2 files changed, 15 deletions(-) diff --git a/src/memory_tracker-inl.h b/src/memory_tracker-inl.h index 8436a00bf5..657835ab54 100644 --- a/src/memory_tracker-inl.h +++ b/src/memory_tracker-inl.h @@ -109,16 +109,6 @@ void MemoryTracker::TrackField(const char* edge_name, TrackField(edge_name, value.get(), node_name); } -template -void MemoryTracker::TrackField(const char* edge_name, - const std::shared_ptr& value, - const char* node_name) { - if (value.get() == nullptr) { - return; - } - TrackField(edge_name, value.get(), node_name); -} - template void MemoryTracker::TrackField(const char* edge_name, const BaseObjectPtrImpl& value, diff --git a/src/memory_tracker.h b/src/memory_tracker.h index d9b897823b..ebd33d259c 100644 --- a/src/memory_tracker.h +++ b/src/memory_tracker.h @@ -140,11 +140,6 @@ class MemoryTracker { inline void TrackField(const char* edge_name, const std::unique_ptr& value, const char* node_name = nullptr); - - template - inline void TrackField(const char* edge_name, - const std::shared_ptr& value, - const char* node_name = nullptr); template void TrackField(const char* edge_name, const BaseObjectPtrImpl& value,