From 4af117434df69a90d71922cd8a674311317fa821 Mon Sep 17 00:00:00 2001 From: historic_bruno Date: Sun, 14 Jun 2015 23:45:15 +0000 Subject: [PATCH] Fixes clang unused parameter warning This was SVN commit r16770. --- source/scriptinterface/third_party/ObjectToIDMap.h | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/source/scriptinterface/third_party/ObjectToIDMap.h b/source/scriptinterface/third_party/ObjectToIDMap.h index 4a5f9ca2f8..8a5911bb5e 100644 --- a/source/scriptinterface/third_party/ObjectToIDMap.h +++ b/source/scriptinterface/third_party/ObjectToIDMap.h @@ -34,9 +34,10 @@ class ObjectIdCache typedef js::PointerHasher Hasher; typedef js::HashMap ObjectIdTable; - public: + NONCOPYABLE(ObjectIdCache); - ObjectIdCache(shared_ptr rt) +public: + ObjectIdCache(shared_ptr rt) : table_(nullptr), m_rt(rt) { JS_AddExtraGCRootsTracer(m_rt->m_rt, ObjectIdCache::Trace, this); @@ -100,11 +101,7 @@ class ObjectIdCache return table_->has(obj); } - private: - - ObjectIdCache(const ObjectIdCache&) {}; - ObjectIdCache& operator= (const ObjectIdCache& other) {}; - +private: static void keyMarkCallback(JSTracer *trc, JSObject *key, void *data) { ObjectIdTable* table = static_cast(data);