Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(94)

Unified Diff: third_party/WebKit/Source/bindings/core/v8/Dictionary.h

Issue 2272313003: binding: Makes ExceptionState STACK_ALLOCATED(). (Closed)
Patch Set: . Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/bindings/core/v8/Dictionary.h
diff --git a/third_party/WebKit/Source/bindings/core/v8/Dictionary.h b/third_party/WebKit/Source/bindings/core/v8/Dictionary.h
index 6ee571f4e71e86f9936d6de1523ed45ee7378cd4..926a02323042fc70db5706b04c0325930de28a8b 100644
--- a/third_party/WebKit/Source/bindings/core/v8/Dictionary.h
+++ b/third_party/WebKit/Source/bindings/core/v8/Dictionary.h
@@ -28,7 +28,6 @@
#include "bindings/core/v8/DictionaryIterator.h"
#include "bindings/core/v8/ExceptionMessages.h"
-#include "bindings/core/v8/ExceptionState.h"
#include "bindings/core/v8/Nullable.h"
#include "bindings/core/v8/ScriptValue.h"
#include "bindings/core/v8/V8Binding.h"
@@ -43,6 +42,7 @@
namespace blink {
+class ExceptionState;
class ExecutionContext;
// Dictionary class provides ways to retrieve property values as C++ objects
@@ -51,9 +51,16 @@ class ExecutionContext;
class CORE_EXPORT Dictionary final {
DISALLOW_NEW_EXCEPT_PLACEMENT_NEW();
public:
- Dictionary();
- Dictionary(const v8::Local<v8::Value>& options, v8::Isolate*, ExceptionState&);
- ~Dictionary();
+ Dictionary()
+ : m_isolate(nullptr) { }
+ Dictionary(v8::Isolate* isolate, const v8::Local<v8::Value>& options)
+ : m_options(options)
+ , m_isolate(isolate)
+ {
+ DCHECK(m_isolate);
+ }
+ Dictionary(const v8::Local<v8::Value>& options, v8::Isolate* isolate, ExceptionState&) // DEPRECATED
+ : Dictionary(isolate, options) { }
Dictionary& operator=(const Dictionary&);
@@ -86,14 +93,13 @@ private:
v8::Local<v8::Value> m_options;
v8::Isolate* m_isolate;
- ExceptionState* m_exceptionState;
};
template<>
struct NativeValueTraits<Dictionary> {
- static inline Dictionary nativeValue(v8::Isolate* isolate, v8::Local<v8::Value> value, ExceptionState& exceptionState)
+ static inline Dictionary nativeValue(v8::Isolate* isolate, v8::Local<v8::Value> value, ExceptionState&)
{
- return Dictionary(value, isolate, exceptionState);
+ return Dictionary(isolate, value);
}
};

Powered by Google App Engine
This is Rietveld 408576698