- Source/WebCore/ChangeLog +54 lines
Lines 1-3 Source/WebCore/ChangeLog_sec1
1
2014-06-12  Sam Weinig  <sam@webkit.org>
2
3
        Constructors should eagerly reify their properties too
4
        https://bugs.webkit.org/show_bug.cgi?id=133822
5
6
        Reviewed by NOBODY (OOPS!).
7
8
        * bindings/scripts/CodeGeneratorJS.pm:
9
        (GenerateConstructorDeclaration):
10
        Constructors should never need to use the lazy property HashTable, so we can just
11
        remove its getOwnPropertySlot completely.
12
13
        (ConstructorHasProperties):
14
        Add helper to determine if we need to reify any properties.
15
16
        (GenerateConstructorHelperMethods):
17
        Reify if needed, and remove the implementation of getOwnPropertySlot.
18
19
        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
20
        * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
21
        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
22
        * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
23
        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
24
        * bindings/scripts/test/JS/JSTestEventConstructor.h:
25
        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
26
        * bindings/scripts/test/JS/JSTestEventTarget.h:
27
        * bindings/scripts/test/JS/JSTestException.cpp:
28
        * bindings/scripts/test/JS/JSTestException.h:
29
        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
30
        * bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
31
        * bindings/scripts/test/JS/JSTestInterface.cpp:
32
        * bindings/scripts/test/JS/JSTestInterface.h:
33
        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
34
        * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
35
        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
36
        * bindings/scripts/test/JS/JSTestNamedConstructor.h:
37
        * bindings/scripts/test/JS/JSTestNode.cpp:
38
        * bindings/scripts/test/JS/JSTestNode.h:
39
        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
40
        * bindings/scripts/test/JS/JSTestNondeterministic.h:
41
        * bindings/scripts/test/JS/JSTestObj.cpp:
42
        * bindings/scripts/test/JS/JSTestObj.h:
43
        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
44
        * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
45
        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
46
        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
47
        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
48
        * bindings/scripts/test/JS/JSTestTypedefs.h:
49
        * bindings/scripts/test/JS/JSattribute.cpp:
50
        * bindings/scripts/test/JS/JSattribute.h:
51
        * bindings/scripts/test/JS/JSreadonly.cpp:
52
        * bindings/scripts/test/JS/JSreadonly.h:
53
        Update tests.
54
1
2014-06-12  Anders Carlsson  <andersca@apple.com>
55
2014-06-12  Anders Carlsson  <andersca@apple.com>
2
56
3
        Add a space after the comma.
57
        Add a space after the comma.
- Source/WebCore/bindings/scripts/CodeGeneratorJS.pm -19 / +23 lines
Lines 4304-4310 sub GenerateConstructorDeclaration Source/WebCore/bindings/scripts/CodeGeneratorJS.pm_sec1
4304
    push(@$outputArray, "        return ptr;\n");
4304
    push(@$outputArray, "        return ptr;\n");
4305
    push(@$outputArray, "    }\n\n");
4305
    push(@$outputArray, "    }\n\n");
4306
4306
4307
    push(@$outputArray, "    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);\n");
4308
    push(@$outputArray, "    DECLARE_INFO;\n");
4307
    push(@$outputArray, "    DECLARE_INFO;\n");
4309
4308
4310
    push(@$outputArray, "    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)\n");
4309
    push(@$outputArray, "    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)\n");
Lines 4585-4590 END Source/WebCore/bindings/scripts/CodeGeneratorJS.pm_sec2
4585
    }
4584
    }
4586
}
4585
}
4587
4586
4587
sub ConstructorHasProperties
4588
{
4589
    my $interface = shift;
4590
4591
    foreach my $constant (@{$interface->constants}) {
4592
        return 1;
4593
    }
4594
4595
    foreach my $attribute (@{$interface->attributes}) {
4596
        next unless ($attribute->isStatic);
4597
        return 1;
4598
    }
4599
4600
    foreach my $function (@{$interface->functions}) {
4601
        next unless ($function->isStatic);
4602
        return 1;
4603
    }
4604
4605
    return 0;
4606
}
4607
4588
sub GenerateConstructorHelperMethods
4608
sub GenerateConstructorHelperMethods
4589
{
4609
{
4590
    my $outputArray = shift;
4610
    my $outputArray = shift;
Lines 4627-4633 sub GenerateConstructorHelperMethods Source/WebCore/bindings/scripts/CodeGeneratorJS.pm_sec3
4627
        } else {
4647
        } else {
4628
            push(@$outputArray, "const ClassInfo ${constructorClassName}::s_info = { \"${visibleInterfaceName}Constructor\", &Base::s_info, &${constructorClassName}Table, 0, CREATE_METHOD_TABLE($constructorClassName) };\n\n");
4648
            push(@$outputArray, "const ClassInfo ${constructorClassName}::s_info = { \"${visibleInterfaceName}Constructor\", &Base::s_info, &${constructorClassName}Table, 0, CREATE_METHOD_TABLE($constructorClassName) };\n\n");
4629
        }
4649
        }
4630
4631
        push(@$outputArray, "${constructorClassName}::${constructorClassName}(Structure* structure, JSDOMGlobalObject* globalObject)\n");
4650
        push(@$outputArray, "${constructorClassName}::${constructorClassName}(Structure* structure, JSDOMGlobalObject* globalObject)\n");
4632
        push(@$outputArray, "    : DOMConstructorObject(structure, globalObject)\n");
4651
        push(@$outputArray, "    : DOMConstructorObject(structure, globalObject)\n");
4633
        push(@$outputArray, "{\n}\n\n");
4652
        push(@$outputArray, "{\n}\n\n");
Lines 4649-4672 sub GenerateConstructorHelperMethods Source/WebCore/bindings/scripts/CodeGeneratorJS.pm_sec4
4649
        push(@$outputArray, "    putDirect(vm, vm.propertyNames->prototype, ${protoClassName}::self(vm, globalObject), DontDelete | ReadOnly);\n");
4668
        push(@$outputArray, "    putDirect(vm, vm.propertyNames->prototype, ${protoClassName}::self(vm, globalObject), DontDelete | ReadOnly);\n");
4650
    }
4669
    }
4651
    push(@$outputArray, "    putDirect(vm, vm.propertyNames->length, jsNumber(${leastConstructorLength}), ReadOnly | DontDelete | DontEnum);\n") if defined $leastConstructorLength;
4670
    push(@$outputArray, "    putDirect(vm, vm.propertyNames->length, jsNumber(${leastConstructorLength}), ReadOnly | DontDelete | DontEnum);\n") if defined $leastConstructorLength;
4652
    push(@$outputArray, "}\n\n");
4671
    push(@$outputArray, "    reifyStaticProperties(vm, ${className}ConstructorTableValues, *this);\n") if ConstructorHasProperties($interface);
4653
4654
    if (!$generatingNamedConstructor) {
4655
        my $hasStaticFunctions = 0;
4656
        foreach my $function (@{$interface->functions}) {
4657
            if ($function->isStatic) {
4658
                $hasStaticFunctions = 1;
4659
                last;
4660
            }
4661
        }
4662
4672
4663
        my $kind = $hasStaticFunctions ? "Property" : "Value";
4673
    push(@$outputArray, "}\n\n");
4664
4665
        push(@$outputArray, "bool ${constructorClassName}::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)\n");
4666
        push(@$outputArray, "{\n");
4667
        push(@$outputArray, "    return getStatic${kind}Slot<${constructorClassName}, JSDOMWrapper>(exec, " . constructorHashTableAccessor($interface->extendedAttributes->{"JSNoStaticTables"}, $constructorClassName) . ", jsCast<${constructorClassName}*>(object), propertyName, slot);\n");
4668
        push(@$outputArray, "}\n\n");
4669
    }
4670
4674
4671
    if (IsConstructable($interface)) {
4675
    if (IsConstructable($interface)) {
4672
        if (!$interface->extendedAttributes->{"NamedConstructor"} || $generatingNamedConstructor) {
4676
        if (!$interface->extendedAttributes->{"NamedConstructor"} || $generatingNamedConstructor) {
- Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.cpp -5 lines
Lines 78-88 void JSTestActiveDOMObjectConstructor::f Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.cpp_sec1
78
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
78
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
79
}
79
}
80
80
81
bool JSTestActiveDOMObjectConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
82
{
83
    return getStaticValueSlot<JSTestActiveDOMObjectConstructor, JSDOMWrapper>(exec, JSTestActiveDOMObjectConstructorTable, jsCast<JSTestActiveDOMObjectConstructor*>(object), propertyName, slot);
84
}
85
86
/* Hash table for prototype */
81
/* Hash table for prototype */
87
82
88
static const struct CompactHashIndex JSTestActiveDOMObjectPrototypeTableIndex[4] = {
83
static const struct CompactHashIndex JSTestActiveDOMObjectPrototypeTableIndex[4] = {
- Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.h -1 lines
Lines 134-140 public: Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.h_sec1
134
        return ptr;
134
        return ptr;
135
    }
135
    }
136
136
137
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
138
    DECLARE_INFO;
137
    DECLARE_INFO;
139
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
138
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
140
    {
139
    {
- Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp -5 lines
Lines 74-84 void JSTestCustomNamedGetterConstructor: Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp_sec1
74
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
74
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
75
}
75
}
76
76
77
bool JSTestCustomNamedGetterConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
78
{
79
    return getStaticValueSlot<JSTestCustomNamedGetterConstructor, JSDOMWrapper>(exec, JSTestCustomNamedGetterConstructorTable, jsCast<JSTestCustomNamedGetterConstructor*>(object), propertyName, slot);
80
}
81
82
/* Hash table for prototype */
77
/* Hash table for prototype */
83
78
84
static const struct CompactHashIndex JSTestCustomNamedGetterPrototypeTableIndex[2] = {
79
static const struct CompactHashIndex JSTestCustomNamedGetterPrototypeTableIndex[2] = {
- Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.h -1 lines
Lines 138-144 public: Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.h_sec1
138
        return ptr;
138
        return ptr;
139
    }
139
    }
140
140
141
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
142
    DECLARE_INFO;
141
    DECLARE_INFO;
143
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
142
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
144
    {
143
    {
- Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp -5 lines
Lines 99-109 void JSTestEventConstructorConstructor:: Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp_sec1
99
    putDirect(vm, vm.propertyNames->length, jsNumber(1), ReadOnly | DontDelete | DontEnum);
99
    putDirect(vm, vm.propertyNames->length, jsNumber(1), ReadOnly | DontDelete | DontEnum);
100
}
100
}
101
101
102
bool JSTestEventConstructorConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
103
{
104
    return getStaticValueSlot<JSTestEventConstructorConstructor, JSDOMWrapper>(exec, JSTestEventConstructorConstructorTable, jsCast<JSTestEventConstructorConstructor*>(object), propertyName, slot);
105
}
106
107
ConstructType JSTestEventConstructorConstructor::getConstructData(JSCell*, ConstructData& constructData)
102
ConstructType JSTestEventConstructorConstructor::getConstructData(JSCell*, ConstructData& constructData)
108
{
103
{
109
    constructData.native.function = constructJSTestEventConstructor;
104
    constructData.native.function = constructJSTestEventConstructor;
- Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.h -1 lines
Lines 135-141 public: Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.h_sec1
135
        return ptr;
135
        return ptr;
136
    }
136
    }
137
137
138
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
139
    DECLARE_INFO;
138
    DECLARE_INFO;
140
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
139
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
141
    {
140
    {
- Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.cpp -5 lines
Lines 80-90 void JSTestEventTargetConstructor::finis Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.cpp_sec1
80
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
80
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
81
}
81
}
82
82
83
bool JSTestEventTargetConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
84
{
85
    return getStaticValueSlot<JSTestEventTargetConstructor, JSDOMWrapper>(exec, JSTestEventTargetConstructorTable, jsCast<JSTestEventTargetConstructor*>(object), propertyName, slot);
86
}
87
88
/* Hash table for prototype */
83
/* Hash table for prototype */
89
84
90
static const struct CompactHashIndex JSTestEventTargetPrototypeTableIndex[8] = {
85
static const struct CompactHashIndex JSTestEventTargetPrototypeTableIndex[8] = {
- Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.h -1 lines
Lines 142-148 public: Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.h_sec1
142
        return ptr;
142
        return ptr;
143
    }
143
    }
144
144
145
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
146
    DECLARE_INFO;
145
    DECLARE_INFO;
147
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
146
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
148
    {
147
    {
- Source/WebCore/bindings/scripts/test/JS/JSTestException.cpp -5 lines
Lines 73-83 void JSTestExceptionConstructor::finishC Source/WebCore/bindings/scripts/test/JS/JSTestException.cpp_sec1
73
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
73
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
74
}
74
}
75
75
76
bool JSTestExceptionConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
77
{
78
    return getStaticValueSlot<JSTestExceptionConstructor, JSDOMWrapper>(exec, JSTestExceptionConstructorTable, jsCast<JSTestExceptionConstructor*>(object), propertyName, slot);
79
}
80
81
/* Hash table for prototype */
76
/* Hash table for prototype */
82
77
83
static const struct CompactHashIndex JSTestExceptionPrototypeTableIndex[2] = {
78
static const struct CompactHashIndex JSTestExceptionPrototypeTableIndex[2] = {
- Source/WebCore/bindings/scripts/test/JS/JSTestException.h -1 lines
Lines 134-140 public: Source/WebCore/bindings/scripts/test/JS/JSTestException.h_sec1
134
        return ptr;
134
        return ptr;
135
    }
135
    }
136
136
137
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
138
    DECLARE_INFO;
137
    DECLARE_INFO;
139
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
138
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
140
    {
139
    {
- Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp -5 lines
Lines 56-66 void JSTestGenerateIsReachableConstructo Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp_sec1
56
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
56
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
57
}
57
}
58
58
59
bool JSTestGenerateIsReachableConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
60
{
61
    return getStaticValueSlot<JSTestGenerateIsReachableConstructor, JSDOMWrapper>(exec, JSTestGenerateIsReachableConstructorTable, jsCast<JSTestGenerateIsReachableConstructor*>(object), propertyName, slot);
62
}
63
64
/* Hash table for prototype */
59
/* Hash table for prototype */
65
60
66
static const struct CompactHashIndex JSTestGenerateIsReachablePrototypeTableIndex[2] = {
61
static const struct CompactHashIndex JSTestGenerateIsReachablePrototypeTableIndex[2] = {
- Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.h -1 lines
Lines 133-139 public: Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.h_sec1
133
        return ptr;
133
        return ptr;
134
    }
134
    }
135
135
136
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
137
    DECLARE_INFO;
136
    DECLARE_INFO;
138
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
137
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
139
    {
138
    {
- Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp -5 / +1 lines
Lines 195-205 void JSTestInterfaceConstructor::finishC Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp_sec1
195
    ASSERT(inherits(info()));
195
    ASSERT(inherits(info()));
196
    putDirect(vm, vm.propertyNames->prototype, JSTestInterfacePrototype::self(vm, globalObject), DontDelete | ReadOnly);
196
    putDirect(vm, vm.propertyNames->prototype, JSTestInterfacePrototype::self(vm, globalObject), DontDelete | ReadOnly);
197
    putDirect(vm, vm.propertyNames->length, jsNumber(1), ReadOnly | DontDelete | DontEnum);
197
    putDirect(vm, vm.propertyNames->length, jsNumber(1), ReadOnly | DontDelete | DontEnum);
198
}
198
    reifyStaticProperties(vm, JSTestInterfaceConstructorTableValues, *this);
199
200
bool JSTestInterfaceConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
201
{
202
    return getStaticPropertySlot<JSTestInterfaceConstructor, JSDOMWrapper>(exec, JSTestInterfaceConstructorTable, jsCast<JSTestInterfaceConstructor*>(object), propertyName, slot);
203
}
199
}
204
200
205
#if ENABLE(TEST_INTERFACE)
201
#if ENABLE(TEST_INTERFACE)
- Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h -1 lines
Lines 161-167 public: Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h_sec1
161
        return ptr;
161
        return ptr;
162
    }
162
    }
163
163
164
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
165
    DECLARE_INFO;
164
    DECLARE_INFO;
166
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
165
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
167
    {
166
    {
- Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp -5 lines
Lines 60-70 void JSTestMediaQueryListListenerConstru Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp_sec1
60
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
60
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
61
}
61
}
62
62
63
bool JSTestMediaQueryListListenerConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
64
{
65
    return getStaticValueSlot<JSTestMediaQueryListListenerConstructor, JSDOMWrapper>(exec, JSTestMediaQueryListListenerConstructorTable, jsCast<JSTestMediaQueryListListenerConstructor*>(object), propertyName, slot);
66
}
67
68
/* Hash table for prototype */
63
/* Hash table for prototype */
69
64
70
static const struct CompactHashIndex JSTestMediaQueryListListenerPrototypeTableIndex[4] = {
65
static const struct CompactHashIndex JSTestMediaQueryListListenerPrototypeTableIndex[4] = {
- Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.h -1 lines
Lines 133-139 public: Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.h_sec1
133
        return ptr;
133
        return ptr;
134
    }
134
    }
135
135
136
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
137
    DECLARE_INFO;
136
    DECLARE_INFO;
138
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
137
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
139
    {
138
    {
- Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.cpp -5 lines
Lines 59-69 void JSTestNamedConstructorConstructor:: Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.cpp_sec1
59
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
59
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
60
}
60
}
61
61
62
bool JSTestNamedConstructorConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
63
{
64
    return getStaticValueSlot<JSTestNamedConstructorConstructor, JSDOMWrapper>(exec, JSTestNamedConstructorConstructorTable, jsCast<JSTestNamedConstructorConstructor*>(object), propertyName, slot);
65
}
66
67
EncodedJSValue JSC_HOST_CALL JSTestNamedConstructorNamedConstructor::constructJSTestNamedConstructor(ExecState* exec)
62
EncodedJSValue JSC_HOST_CALL JSTestNamedConstructorNamedConstructor::constructJSTestNamedConstructor(ExecState* exec)
68
{
63
{
69
    JSTestNamedConstructorNamedConstructor* castedThis = jsCast<JSTestNamedConstructorNamedConstructor*>(exec->callee());
64
    JSTestNamedConstructorNamedConstructor* castedThis = jsCast<JSTestNamedConstructorNamedConstructor*>(exec->callee());
- Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.h -1 lines
Lines 135-141 public: Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.h_sec1
135
        return ptr;
135
        return ptr;
136
    }
136
    }
137
137
138
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
139
    DECLARE_INFO;
138
    DECLARE_INFO;
140
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
139
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
141
    {
140
    {
- Source/WebCore/bindings/scripts/test/JS/JSTestNode.cpp -5 lines
Lines 66-76 void JSTestNodeConstructor::finishCreati Source/WebCore/bindings/scripts/test/JS/JSTestNode.cpp_sec1
66
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
66
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
67
}
67
}
68
68
69
bool JSTestNodeConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
70
{
71
    return getStaticValueSlot<JSTestNodeConstructor, JSDOMWrapper>(exec, JSTestNodeConstructorTable, jsCast<JSTestNodeConstructor*>(object), propertyName, slot);
72
}
73
74
ConstructType JSTestNodeConstructor::getConstructData(JSCell*, ConstructData& constructData)
69
ConstructType JSTestNodeConstructor::getConstructData(JSCell*, ConstructData& constructData)
75
{
70
{
76
    constructData.native.function = constructJSTestNode;
71
    constructData.native.function = constructJSTestNode;
- Source/WebCore/bindings/scripts/test/JS/JSTestNode.h -1 lines
Lines 104-110 public: Source/WebCore/bindings/scripts/test/JS/JSTestNode.h_sec1
104
        return ptr;
104
        return ptr;
105
    }
105
    }
106
106
107
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
108
    DECLARE_INFO;
107
    DECLARE_INFO;
109
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
108
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
110
    {
109
    {
- Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.cpp -5 lines
Lines 68-78 void JSTestNondeterministicConstructor:: Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.cpp_sec1
68
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
68
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
69
}
69
}
70
70
71
bool JSTestNondeterministicConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
72
{
73
    return getStaticValueSlot<JSTestNondeterministicConstructor, JSDOMWrapper>(exec, JSTestNondeterministicConstructorTable, jsCast<JSTestNondeterministicConstructor*>(object), propertyName, slot);
74
}
75
76
/* Hash table for prototype */
71
/* Hash table for prototype */
77
72
78
static const struct CompactHashIndex JSTestNondeterministicPrototypeTableIndex[17] = {
73
static const struct CompactHashIndex JSTestNondeterministicPrototypeTableIndex[17] = {
- Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.h -1 lines
Lines 133-139 public: Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.h_sec1
133
        return ptr;
133
        return ptr;
134
    }
134
    }
135
135
136
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
137
    DECLARE_INFO;
136
    DECLARE_INFO;
138
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
137
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
139
    {
138
    {
- Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp -5 / +1 lines
Lines 244-254 void JSTestObjConstructor::finishCreatio Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp_sec1
244
    ASSERT(inherits(info()));
244
    ASSERT(inherits(info()));
245
    putDirect(vm, vm.propertyNames->prototype, JSTestObjPrototype::self(vm, globalObject), DontDelete | ReadOnly);
245
    putDirect(vm, vm.propertyNames->prototype, JSTestObjPrototype::self(vm, globalObject), DontDelete | ReadOnly);
246
    putDirect(vm, vm.propertyNames->length, jsNumber(1), ReadOnly | DontDelete | DontEnum);
246
    putDirect(vm, vm.propertyNames->length, jsNumber(1), ReadOnly | DontDelete | DontEnum);
247
}
247
    reifyStaticProperties(vm, JSTestObjConstructorTableValues, *this);
248
249
bool JSTestObjConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
250
{
251
    return getStaticPropertySlot<JSTestObjConstructor, JSDOMWrapper>(exec, JSTestObjConstructorTable, jsCast<JSTestObjConstructor*>(object), propertyName, slot);
252
}
248
}
253
249
254
ConstructType JSTestObjConstructor::getConstructData(JSCell*, ConstructData& constructData)
250
ConstructType JSTestObjConstructor::getConstructData(JSCell*, ConstructData& constructData)
- Source/WebCore/bindings/scripts/test/JS/JSTestObj.h -1 lines
Lines 147-153 public: Source/WebCore/bindings/scripts/test/JS/JSTestObj.h_sec1
147
        return ptr;
147
        return ptr;
148
    }
148
    }
149
149
150
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
151
    DECLARE_INFO;
150
    DECLARE_INFO;
152
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
151
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
153
    {
152
    {
- Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp -5 lines
Lines 125-135 void JSTestOverloadedConstructorsConstru Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp_sec1
125
    putDirect(vm, vm.propertyNames->length, jsNumber(1), ReadOnly | DontDelete | DontEnum);
125
    putDirect(vm, vm.propertyNames->length, jsNumber(1), ReadOnly | DontDelete | DontEnum);
126
}
126
}
127
127
128
bool JSTestOverloadedConstructorsConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
129
{
130
    return getStaticValueSlot<JSTestOverloadedConstructorsConstructor, JSDOMWrapper>(exec, JSTestOverloadedConstructorsConstructorTable, jsCast<JSTestOverloadedConstructorsConstructor*>(object), propertyName, slot);
131
}
132
133
ConstructType JSTestOverloadedConstructorsConstructor::getConstructData(JSCell*, ConstructData& constructData)
128
ConstructType JSTestOverloadedConstructorsConstructor::getConstructData(JSCell*, ConstructData& constructData)
134
{
129
{
135
    constructData.native.function = constructJSTestOverloadedConstructors;
130
    constructData.native.function = constructJSTestOverloadedConstructors;
- Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.h -1 lines
Lines 133-139 public: Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.h_sec1
133
        return ptr;
133
        return ptr;
134
    }
134
    }
135
135
136
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
137
    DECLARE_INFO;
136
    DECLARE_INFO;
138
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
137
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
139
    {
138
    {
- Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp -5 lines
Lines 64-74 void JSTestSerializedScriptValueInterfac Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp_sec1
64
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
64
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
65
}
65
}
66
66
67
bool JSTestSerializedScriptValueInterfaceConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
68
{
69
    return getStaticValueSlot<JSTestSerializedScriptValueInterfaceConstructor, JSDOMWrapper>(exec, JSTestSerializedScriptValueInterfaceConstructorTable, jsCast<JSTestSerializedScriptValueInterfaceConstructor*>(object), propertyName, slot);
70
}
71
72
/* Hash table for prototype */
67
/* Hash table for prototype */
73
68
74
static const struct CompactHashIndex JSTestSerializedScriptValueInterfacePrototypeTableIndex[17] = {
69
static const struct CompactHashIndex JSTestSerializedScriptValueInterfacePrototypeTableIndex[17] = {
- Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h -1 lines
Lines 139-145 public: Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h_sec1
139
        return ptr;
139
        return ptr;
140
    }
140
    }
141
141
142
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
143
    DECLARE_INFO;
142
    DECLARE_INFO;
144
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
143
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
145
    {
144
    {
- Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp -5 / +1 lines
Lines 99-109 void JSTestTypedefsConstructor::finishCr Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp_sec1
99
    ASSERT(inherits(info()));
99
    ASSERT(inherits(info()));
100
    putDirect(vm, vm.propertyNames->prototype, JSTestTypedefsPrototype::self(vm, globalObject), DontDelete | ReadOnly);
100
    putDirect(vm, vm.propertyNames->prototype, JSTestTypedefsPrototype::self(vm, globalObject), DontDelete | ReadOnly);
101
    putDirect(vm, vm.propertyNames->length, jsNumber(2), ReadOnly | DontDelete | DontEnum);
101
    putDirect(vm, vm.propertyNames->length, jsNumber(2), ReadOnly | DontDelete | DontEnum);
102
}
102
    reifyStaticProperties(vm, JSTestTypedefsConstructorTableValues, *this);
103
104
bool JSTestTypedefsConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
105
{
106
    return getStaticValueSlot<JSTestTypedefsConstructor, JSDOMWrapper>(exec, JSTestTypedefsConstructorTable, jsCast<JSTestTypedefsConstructor*>(object), propertyName, slot);
107
}
103
}
108
104
109
ConstructType JSTestTypedefsConstructor::getConstructData(JSCell*, ConstructData& constructData)
105
ConstructType JSTestTypedefsConstructor::getConstructData(JSCell*, ConstructData& constructData)
- Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.h -1 lines
Lines 134-140 public: Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.h_sec1
134
        return ptr;
134
        return ptr;
135
    }
135
    }
136
136
137
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
138
    DECLARE_INFO;
137
    DECLARE_INFO;
139
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
138
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
140
    {
139
    {
- Source/WebCore/bindings/scripts/test/JS/JSattribute.cpp -5 lines
Lines 59-69 void JSattributeConstructor::finishCreat Source/WebCore/bindings/scripts/test/JS/JSattribute.cpp_sec1
59
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
59
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
60
}
60
}
61
61
62
bool JSattributeConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
63
{
64
    return getStaticValueSlot<JSattributeConstructor, JSDOMWrapper>(exec, JSattributeConstructorTable, jsCast<JSattributeConstructor*>(object), propertyName, slot);
65
}
66
67
/* Hash table for prototype */
62
/* Hash table for prototype */
68
63
69
static const struct CompactHashIndex JSattributePrototypeTableIndex[4] = {
64
static const struct CompactHashIndex JSattributePrototypeTableIndex[4] = {
- Source/WebCore/bindings/scripts/test/JS/JSattribute.h -1 lines
Lines 133-139 public: Source/WebCore/bindings/scripts/test/JS/JSattribute.h_sec1
133
        return ptr;
133
        return ptr;
134
    }
134
    }
135
135
136
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
137
    DECLARE_INFO;
136
    DECLARE_INFO;
138
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
137
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
139
    {
138
    {
- Source/WebCore/bindings/scripts/test/JS/JSreadonly.cpp -5 lines
Lines 56-66 void JSreadonlyConstructor::finishCreati Source/WebCore/bindings/scripts/test/JS/JSreadonly.cpp_sec1
56
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
56
    putDirect(vm, vm.propertyNames->length, jsNumber(0), ReadOnly | DontDelete | DontEnum);
57
}
57
}
58
58
59
bool JSreadonlyConstructor::getOwnPropertySlot(JSObject* object, ExecState* exec, PropertyName propertyName, PropertySlot& slot)
60
{
61
    return getStaticValueSlot<JSreadonlyConstructor, JSDOMWrapper>(exec, JSreadonlyConstructorTable, jsCast<JSreadonlyConstructor*>(object), propertyName, slot);
62
}
63
64
/* Hash table for prototype */
59
/* Hash table for prototype */
65
60
66
static const struct CompactHashIndex JSreadonlyPrototypeTableIndex[2] = {
61
static const struct CompactHashIndex JSreadonlyPrototypeTableIndex[2] = {
- Source/WebCore/bindings/scripts/test/JS/JSreadonly.h -1 lines
Lines 133-139 public: Source/WebCore/bindings/scripts/test/JS/JSreadonly.h_sec1
133
        return ptr;
133
        return ptr;
134
    }
134
    }
135
135
136
    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);
137
    DECLARE_INFO;
136
    DECLARE_INFO;
138
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
137
    static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype)
139
    {
138
    {

Return to Bug 133822