| Index: third_party/WebKit/Source/bindings/tests/results/core/DoubleOrString.h
|
| diff --git a/third_party/WebKit/Source/bindings/tests/results/core/DoubleOrString.h b/third_party/WebKit/Source/bindings/tests/results/core/DoubleOrString.h
|
| index 976633bc2084bf5aefc20998be69c64aefb18e2f..d2aee6aa4eef7f47875ad5847d048c0c88ecba63 100644
|
| --- a/third_party/WebKit/Source/bindings/tests/results/core/DoubleOrString.h
|
| +++ b/third_party/WebKit/Source/bindings/tests/results/core/DoubleOrString.h
|
| @@ -17,59 +17,58 @@
|
| namespace blink {
|
|
|
| class CORE_EXPORT DoubleOrString final {
|
| - DISALLOW_NEW_EXCEPT_PLACEMENT_NEW();
|
| -public:
|
| - DoubleOrString();
|
| - bool isNull() const { return m_type == SpecificTypeNone; }
|
| -
|
| - bool isDouble() const { return m_type == SpecificTypeDouble; }
|
| - double getAsDouble() const;
|
| - void setDouble(double);
|
| - static DoubleOrString fromDouble(double);
|
| -
|
| - bool isString() const { return m_type == SpecificTypeString; }
|
| - String getAsString() const;
|
| - void setString(String);
|
| - static DoubleOrString fromString(String);
|
| -
|
| - DoubleOrString(const DoubleOrString&);
|
| - ~DoubleOrString();
|
| - DoubleOrString& operator=(const DoubleOrString&);
|
| - DECLARE_TRACE();
|
| -
|
| -private:
|
| - enum SpecificTypes {
|
| - SpecificTypeNone,
|
| - SpecificTypeDouble,
|
| - SpecificTypeString,
|
| - };
|
| - SpecificTypes m_type;
|
| -
|
| - double m_double;
|
| - String m_string;
|
| -
|
| - friend CORE_EXPORT v8::Local<v8::Value> toV8(const DoubleOrString&, v8::Local<v8::Object>, v8::Isolate*);
|
| + DISALLOW_NEW_EXCEPT_PLACEMENT_NEW();
|
| + public:
|
| + DoubleOrString();
|
| + bool isNull() const { return m_type == SpecificTypeNone; }
|
| +
|
| + bool isDouble() const { return m_type == SpecificTypeDouble; }
|
| + double getAsDouble() const;
|
| + void setDouble(double);
|
| + static DoubleOrString fromDouble(double);
|
| +
|
| + bool isString() const { return m_type == SpecificTypeString; }
|
| + String getAsString() const;
|
| + void setString(String);
|
| + static DoubleOrString fromString(String);
|
| +
|
| + DoubleOrString(const DoubleOrString&);
|
| + ~DoubleOrString();
|
| + DoubleOrString& operator=(const DoubleOrString&);
|
| + DECLARE_TRACE();
|
| +
|
| + private:
|
| + enum SpecificTypes {
|
| + SpecificTypeNone,
|
| + SpecificTypeDouble,
|
| + SpecificTypeString,
|
| + };
|
| + SpecificTypes m_type;
|
| +
|
| + double m_double;
|
| + String m_string;
|
| +
|
| + friend CORE_EXPORT v8::Local<v8::Value> toV8(const DoubleOrString&, v8::Local<v8::Object>, v8::Isolate*);
|
| };
|
|
|
| class V8DoubleOrString final {
|
| -public:
|
| - CORE_EXPORT static void toImpl(v8::Isolate*, v8::Local<v8::Value>, DoubleOrString&, UnionTypeConversionMode, ExceptionState&);
|
| + public:
|
| + CORE_EXPORT static void toImpl(v8::Isolate*, v8::Local<v8::Value>, DoubleOrString&, UnionTypeConversionMode, ExceptionState&);
|
| };
|
|
|
| CORE_EXPORT v8::Local<v8::Value> toV8(const DoubleOrString&, v8::Local<v8::Object>, v8::Isolate*);
|
|
|
| template <class CallbackInfo>
|
| -inline void v8SetReturnValue(const CallbackInfo& callbackInfo, DoubleOrString& impl)
|
| -{
|
| - v8SetReturnValue(callbackInfo, toV8(impl, callbackInfo.Holder(), callbackInfo.GetIsolate()));
|
| +inline void v8SetReturnValue(const CallbackInfo& callbackInfo, DoubleOrString& impl) {
|
| + v8SetReturnValue(callbackInfo, toV8(impl, callbackInfo.Holder(), callbackInfo.GetIsolate()));
|
| }
|
|
|
| template <>
|
| struct NativeValueTraits<DoubleOrString> {
|
| - CORE_EXPORT static DoubleOrString nativeValue(v8::Isolate*, v8::Local<v8::Value>, ExceptionState&);
|
| + CORE_EXPORT static DoubleOrString nativeValue(v8::Isolate*, v8::Local<v8::Value>, ExceptionState&);
|
| };
|
|
|
| -} // namespace blink
|
| +} // namespace blink
|
|
|
| // We need to set canInitializeWithMemset=true because HeapVector supports
|
| // items that can initialize with memset or have a vtable. It is safe to
|
| @@ -77,4 +76,4 @@ struct NativeValueTraits<DoubleOrString> {
|
| // See https://codereview.chromium.org/1118993002/#msg5 for more details.
|
| WTF_ALLOW_MOVE_AND_INIT_WITH_MEM_FUNCTIONS(blink::DoubleOrString);
|
|
|
| -#endif // DoubleOrString_h
|
| +#endif // DoubleOrString_h
|
|
|