From 1bf1084f2b10c3b47fd1a588d85d21ed0eb41d0c Mon Sep 17 00:00:00 2001 From: Lorry Tar Creator Date: Tue, 27 Jun 2017 06:07:23 +0000 Subject: webkitgtk-2.16.5 --- .../bytecode/StructureStubClearingWatchpoint.h | 50 +++++++++------------- 1 file changed, 21 insertions(+), 29 deletions(-) (limited to 'Source/JavaScriptCore/bytecode/StructureStubClearingWatchpoint.h') diff --git a/Source/JavaScriptCore/bytecode/StructureStubClearingWatchpoint.h b/Source/JavaScriptCore/bytecode/StructureStubClearingWatchpoint.h index 4c6bdecf4..665c56a98 100644 --- a/Source/JavaScriptCore/bytecode/StructureStubClearingWatchpoint.h +++ b/Source/JavaScriptCore/bytecode/StructureStubClearingWatchpoint.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2012 Apple Inc. All rights reserved. + * Copyright (C) 2012, 2015 Apple Inc. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -23,60 +23,55 @@ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#ifndef StructureStubClearingWatchpoint_h -#define StructureStubClearingWatchpoint_h +#pragma once +#include "ObjectPropertyCondition.h" #include "Watchpoint.h" -#include #if ENABLE(JIT) #include #include -#include -#include -#include -#include namespace JSC { class CodeBlock; +class StructureStubInfo; class WatchpointsOnStructureStubInfo; -struct StructureStubInfo; class StructureStubClearingWatchpoint : public Watchpoint { WTF_MAKE_NONCOPYABLE(StructureStubClearingWatchpoint); WTF_MAKE_FAST_ALLOCATED; public: StructureStubClearingWatchpoint( - WatchpointsOnStructureStubInfo& holder) - : m_holder(holder) - { - } - - StructureStubClearingWatchpoint( + const ObjectPropertyCondition& key, WatchpointsOnStructureStubInfo& holder, - PassOwnPtr next) - : m_holder(holder) - , m_next(next) + std::unique_ptr next) + : m_key(key) + , m_holder(holder) + , m_next(WTFMove(next)) { } virtual ~StructureStubClearingWatchpoint(); static StructureStubClearingWatchpoint* push( + const ObjectPropertyCondition& key, WatchpointsOnStructureStubInfo& holder, - OwnPtr& head); + std::unique_ptr& head); protected: - virtual void fireInternal() override; + void fireInternal(const FireDetail&) override; private: + ObjectPropertyCondition m_key; WatchpointsOnStructureStubInfo& m_holder; - OwnPtr m_next; + std::unique_ptr m_next; }; -class WatchpointsOnStructureStubInfo : public RefCounted { +class WatchpointsOnStructureStubInfo { + WTF_MAKE_NONCOPYABLE(WatchpointsOnStructureStubInfo); + WTF_MAKE_FAST_ALLOCATED; public: WatchpointsOnStructureStubInfo(CodeBlock* codeBlock, StructureStubInfo* stubInfo) : m_codeBlock(codeBlock) @@ -86,11 +81,11 @@ public: ~WatchpointsOnStructureStubInfo(); - StructureStubClearingWatchpoint* addWatchpoint(); + StructureStubClearingWatchpoint* addWatchpoint(const ObjectPropertyCondition& key); static StructureStubClearingWatchpoint* ensureReferenceAndAddWatchpoint( - RefPtr& holderRef, - CodeBlock*, StructureStubInfo*); + std::unique_ptr& holderRef, + CodeBlock*, StructureStubInfo*, const ObjectPropertyCondition& key); CodeBlock* codeBlock() const { return m_codeBlock; } StructureStubInfo* stubInfo() const { return m_stubInfo; } @@ -98,12 +93,9 @@ public: private: CodeBlock* m_codeBlock; StructureStubInfo* m_stubInfo; - OwnPtr m_head; + std::unique_ptr m_head; }; } // namespace JSC #endif // ENABLE(JIT) - -#endif // StructureStubClearingWatchpoint_h - -- cgit v1.2.1