Removing a <link> element with an empty stylesheet shouldn't trigger style recalc.
<http://webkit.org/b/119442>
<rdar://problem/14631785>

Reviewed by Antti Koivisto.

Let Document decide whether or not to do a style recalc after a <link> element is removed.
This avoids unnecessary work when removing a <link> that refers to an empty style sheet.

Some Facebook pages have a <link rel="stylesheet" href="data:text/css;base64,"> that gets
removed during the initial page load, causing style recalc.

* html/HTMLLinkElement.cpp:
(WebCore::HTMLLinkElement::removedFrom):

    Use DeferRecalcStyleIfNeeded. Since the style sheet is being removed, it will either
    cause a recalc (because it's no longer in the set of active sheets) or do nothing.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@153672 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Remove no-arguments constructor to PropertySlot
https://bugs.webkit.org/show_bug.cgi?id=119460

Reviewed by Geoff Garen.

This constructor was unsafe if getValue is subsequently called,
and the property is a getter. Simplest to just remove it.

* runtime/Arguments.cpp:
(JSC::Arguments::defineOwnProperty):
* runtime/JSActivation.cpp:
(JSC::JSActivation::getOwnPropertyDescriptor):
* runtime/JSFunction.cpp:
(JSC::JSFunction::getOwnPropertyDescriptor):
(JSC::JSFunction::getOwnNonIndexPropertyNames):
(JSC::JSFunction::put):
(JSC::JSFunction::defineOwnProperty):
* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::defineOwnProperty):
* runtime/JSGlobalObject.h:
(JSC::JSGlobalObject::hasOwnPropertyForWrite):
* runtime/JSNameScope.cpp:
(JSC::JSNameScope::put):
* runtime/JSONObject.cpp:
(JSC::Stringifier::Holder::appendNextProperty):
(JSC::Walker::walk):
* runtime/JSObject.cpp:
(JSC::JSObject::hasProperty):
(JSC::JSObject::hasOwnProperty):
(JSC::JSObject::reifyStaticFunctionsForDelete):
* runtime/Lookup.h:
(JSC::getStaticPropertyDescriptor):
(JSC::getStaticFunctionDescriptor):
(JSC::getStaticValueDescriptor):
* runtime/ObjectConstructor.cpp:
(JSC::defineProperties):
* runtime/PropertySlot.h:



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@153673 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Incorrect type speculation reported by ToPrimitive
https://bugs.webkit.org/show_bug.cgi?id=119458

Reviewed by Mark Hahnenberg.

Make sure that we report the correct type possibilities for the output
from ToPrimitive

* dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::::executeEffects):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@153674 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Gardening: Touched a line in Platform.h to get all bots to do a clean build.

Not reviewed.

* wtf/Platform.h:



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@153676 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Remove no-arguments constructor to PropertySlot
https://bugs.webkit.org/show_bug.cgi?id=119460

Reviewed by Geoff Garen.

This constructor was unsafe if getValue is subsequently called,
and the property is a getter. Simplest to just remove it.

Source/WebCore: 

* bindings/js/JSDOMWindowCustom.cpp:
(WebCore::JSDOMWindow::getOwnPropertyDescriptor):
(WebCore::DialogHandler::returnValue):
* bindings/js/JSHistoryCustom.cpp:
(WebCore::JSHistory::getOwnPropertyDescriptorDelegate):
* bindings/js/JSLocationCustom.cpp:
(WebCore::JSLocation::getOwnPropertyDescriptorDelegate):
* bindings/js/JSPluginElementFunctions.cpp:
(WebCore::runtimeObjectCustomGetOwnPropertyDescriptor):
* bindings/js/JSStorageCustom.cpp:
(WebCore::JSStorage::deleteProperty):
(WebCore::JSStorage::putDelegate):
* bindings/scripts/CodeGeneratorJS.pm:
(GenerateGetOwnPropertyDescriptorBody):
* bridge/runtime_array.cpp:
(JSC::RuntimeArray::getOwnPropertyDescriptor):
* bridge/runtime_method.cpp:
(JSC::RuntimeMethod::getOwnPropertyDescriptor):
* bridge/runtime_object.cpp:
(JSC::Bindings::RuntimeObject::getOwnPropertyDescriptor):

Source/WebKit2: 

* WebProcess/Plugins/Netscape/JSNPObject.cpp:
(WebKit::JSNPObject::getOwnPropertyDescriptor):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@153677 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed. Skip failing canvas blending tests on AppleWin port.
https://bugs.webkit.org/show_bug.cgi?id=119463.

* platform/win/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@153678 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Give the error object's stack property accessor attributes.
https://bugs.webkit.org/show_bug.cgi?id=119404

Source/JavaScriptCore:

Patch by Chris Curtis <chris_curtis@apple.com> on 2013-08-02
Reviewed by Geoffrey Garen.

Changed the attributes of error object's stack property to allow developers to write
and delete the stack property. This will match the functionality of Chrome. Firefox
allows developers to write the error's stack, but not delete it.

* interpreter/Interpreter.cpp:
(JSC::Interpreter::addStackTraceIfNecessary):
* runtime/ErrorInstance.cpp:
(JSC::ErrorInstance::finishCreation):

LayoutTests:

Patch by Chris Curtis <chris_curtis@apple.com> on 2013-08-02
Reviewed by Geoffrey Garen.

* fast/dom/DOMException/stack-trace-expected.txt:

New tests to show that the error object's stack property is writable and deleteable.
* fast/js/error-object-write-and-detele-for-stack-property-expected.txt: Added.
* fast/js/error-object-write-and-detele-for-stack-property.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@153679 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Update binding test results

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@153680 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Force elements with perspective or preserve-3d to disallow direct composited backgrounds
https://bugs.webkit.org/show_bug.cgi?id=119462
<rdar://problem/14607548>

Reviewed by Simon Fraser.

Source/WebCore:

Bug 119461 (http://wkb.ug/119461) describes how a directly composited
background color can intersect with its children. It's not clear exactly
what the best way to fix that is, but for the moment we should disallow
any element that has perspective or a preserve-3d transform style from
getting a directly composited background.

Test: compositing/background-color/no-composited-background-color-when-perspective.html

* rendering/RenderLayerBacking.cpp:
(WebCore::hasPerspectiveOrPreserves3D): New static helper.
(WebCore::supportsDirectBoxDecorationsComposition): Return false if the above function is true.

LayoutTests:

* compositing/background-color/no-composited-background-color-when-perspective-expected.html: Added.
* compositing/background-color/no-composited-background-color-when-perspective.html: Added.
* compositing/geometry/preserve-3d-switching-expected.txt: Rebaselined.
* compositing/overflow-trumps-transform-style-expected.txt: Rebaselined.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@153681 268f45cc-cd09-0410-ab3c-d52691b4dbfc