[Webkit-unassigned] [Bug 165506] Inspector::InspectorValue class doesn't handle undefined type

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Dec 8 12:01:49 PST 2016


https://bugs.webkit.org/show_bug.cgi?id=165506

--- Comment #4 from Karim <karim at karhm.com> ---
Comment on attachment 296360
  --> https://bugs.webkit.org/attachment.cgi?id=296360
Patch

>Index: Source/JavaScriptCore/ChangeLog
>===================================================================
>--- Source/JavaScriptCore/ChangeLog	(revision 209439)
>+++ Source/JavaScriptCore/ChangeLog	(working copy)
>@@ -1,3 +1,15 @@
>+2016-12-06  Karim H  <karim at karhm.com>
>+
>+        Added undefined type and fixed related issues
>+        https://bugs.webkit.org/show_bug.cgi?id=165506
>+
>+        Reviewed by NOBODY (OOPS!).
>+
>+        * inspector/InspectorValues.cpp:
>+        (Inspector::InspectorValue::undefined):
>+        * inspector/InspectorValues.h:
>+
> 2016-12-06  Alexey Proskuryakov  <ap at apple.com>
> 
>         Correct SDKROOT values in xcconfig files
>Index: Source/JavaScriptCore/inspector/InspectorValues.cpp
>===================================================================
>--- Source/JavaScriptCore/inspector/InspectorValues.cpp	(revision 209405)
>+++ Source/JavaScriptCore/inspector/InspectorValues.cpp	(working copy)
>@@ -485,6 +485,11 @@ Ref<InspectorValue> InspectorValue::null
>     return adoptRef(*new InspectorValue);
> }
> 
>+Ref<InspectorValue> InspectorValue::undefined()
>+{
>+    return adoptRef(*new InspectorValue(Type::Undefined));
>+}
>+
> Ref<InspectorValue> InspectorValue::create(bool value)
> {
>     return adoptRef(*new InspectorValue(value));
>Index: Source/JavaScriptCore/inspector/InspectorValues.h
>===================================================================
>--- Source/JavaScriptCore/inspector/InspectorValues.h	(revision 209405)
>+++ Source/JavaScriptCore/inspector/InspectorValues.h	(working copy)
>@@ -64,11 +64,13 @@ public:
>             break;
>         case Type::Object:
>         case Type::Array:
>+        case Type::Undefined:
>             break;
>         }
>     }
> 
>     static Ref<InspectorValue> null();
>+    static Ref<InspectorValue> undefined();
>     static Ref<InspectorValue> create(bool);
>     static Ref<InspectorValue> create(int);
>     static Ref<InspectorValue> create(double);
>@@ -83,10 +85,12 @@ public:
>         String,
>         Object,
>         Array,
>+        Undefined,
>     };
> 
>     Type type() const { return m_type; }
>     bool isNull() const { return m_type == Type::Null; }
>+    bool isUndefined() const { return m_type == Type::Undefined; }
> 
>     bool asBoolean(bool&) const;
>     bool asInteger(int&) const;

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20161208/3ee8712f/attachment.html>


More information about the webkit-unassigned mailing list