summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit
diff options
context:
space:
mode:
authorabarth@webkit.org <abarth@webkit.org@bbb929c8-8fbe-4397-9dbb-9b2b20218538>2011-06-20 23:54:07 +0000
committerabarth@webkit.org <abarth@webkit.org@bbb929c8-8fbe-4397-9dbb-9b2b20218538>2011-06-20 23:54:07 +0000
commitd633387a5b474d27289aa6df3555cef776462045 (patch)
tree16bf06501a295848b2c5f905f45e4af490751c47 /third_party/WebKit
parent81efb9e6a550269051534932edbbf70e06b4cdbe (diff)
downloadchromium_src-d633387a5b474d27289aa6df3555cef776462045.zip
chromium_src-d633387a5b474d27289aa6df3555cef776462045.tar.gz
chromium_src-d633387a5b474d27289aa6df3555cef776462045.tar.bz2
2011-06-20 Mark Pilgrim <pilgrim@chromium.org>
Reviewed by Adam Barth. IDL generator should throw TypeError instead of SyntaxError on not enough arguments https://bugs.webkit.org/show_bug.cgi?id=63011 To align with WebIDL, we should throw TypeError whenever a function is called with missing required arguments. * fast/canvas/canvas-overloads-drawImageFromRect-expected.txt: * fast/canvas/canvas-overloads-fillText-expected.txt: * fast/canvas/canvas-overloads-strokeText-expected.txt: * fast/canvas/script-tests/canvas-overloads-drawImageFromRect.js: * fast/canvas/script-tests/canvas-overloads-fillText.js: * fast/canvas/script-tests/canvas-overloads-strokeText.js: * fast/canvas/webgl/data-view-test-expected.txt: * http/tests/xmlhttprequest/exceptions-expected.txt: * platform/chromium-mac/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt: * platform/chromium-win/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt: * svg/dom/SVGAngle-expected.txt: * svg/dom/SVGColor-expected.txt: * svg/dom/SVGLength-expected.txt: * svg/dom/SVGLengthList-basics-expected.txt: * svg/dom/SVGMatrix-expected.txt: * svg/dom/SVGNumberList-basics-expected.txt: * svg/dom/SVGPaint-expected.txt: * svg/dom/SVGPoint-expected.txt: * svg/dom/SVGPointList-basics-expected.txt: * svg/dom/SVGStringList-basics-expected.txt: * svg/dom/SVGTransform-expected.txt: * svg/dom/SVGTransformList-basics-expected.txt: * svg/dom/SVGTransformList-expected.txt: * svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt: 2011-06-20 Mark Pilgrim <pilgrim@chromium.org> Reviewed by Adam Barth. IDL generator should throw TypeError instead of SyntaxError on not enough arguments https://bugs.webkit.org/show_bug.cgi?id=63011 To align with WebIDL, we should throw TypeError whenever a function is called with missing required arguments. * bindings/scripts/CodeGeneratorJS.pm: * bindings/scripts/CodeGeneratorV8.pm: * bindings/scripts/test/V8/V8TestObj.cpp: (WebCore::TestObjInternal::methodThatRequiresAllArgsAndThrowsCallback): git-svn-id: svn://svn.chromium.org/blink/trunk@89315 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Diffstat (limited to 'third_party/WebKit')
-rw-r--r--third_party/WebKit/LayoutTests/ChangeLog35
-rw-r--r--third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-drawImageFromRect-expected.txt2
-rw-r--r--third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-fillText-expected.txt6
-rw-r--r--third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-strokeText-expected.txt6
-rw-r--r--third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-drawImageFromRect.js4
-rw-r--r--third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js8
-rw-r--r--third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-strokeText.js8
-rw-r--r--third_party/WebKit/LayoutTests/fast/canvas/webgl/data-view-test-expected.txt36
-rw-r--r--third_party/WebKit/LayoutTests/http/tests/xmlhttprequest/exceptions-expected.txt6
-rw-r--r--third_party/WebKit/LayoutTests/platform/chromium-mac/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt2
-rw-r--r--third_party/WebKit/LayoutTests/platform/chromium-win/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt2
-rw-r--r--third_party/WebKit/LayoutTests/svg/dom/SVGAngle-expected.txt8
-rw-r--r--third_party/WebKit/LayoutTests/svg/dom/SVGColor-expected.txt4
-rw-r--r--third_party/WebKit/LayoutTests/svg/dom/SVGLength-expected.txt2
-rw-r--r--third_party/WebKit/LayoutTests/svg/dom/SVGLengthList-basics-expected.txt16
-rw-r--r--third_party/WebKit/LayoutTests/svg/dom/SVGMatrix-expected.txt40
-rw-r--r--third_party/WebKit/LayoutTests/svg/dom/SVGNumberList-basics-expected.txt16
-rw-r--r--third_party/WebKit/LayoutTests/svg/dom/SVGPaint-expected.txt8
-rw-r--r--third_party/WebKit/LayoutTests/svg/dom/SVGPoint-expected.txt2
-rw-r--r--third_party/WebKit/LayoutTests/svg/dom/SVGPointList-basics-expected.txt14
-rw-r--r--third_party/WebKit/LayoutTests/svg/dom/SVGStringList-basics-expected.txt14
-rw-r--r--third_party/WebKit/LayoutTests/svg/dom/SVGTransform-expected.txt36
-rw-r--r--third_party/WebKit/LayoutTests/svg/dom/SVGTransformList-basics-expected.txt16
-rw-r--r--third_party/WebKit/LayoutTests/svg/dom/SVGTransformList-expected.txt2
-rw-r--r--third_party/WebKit/LayoutTests/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt2
-rw-r--r--third_party/WebKit/Source/WebCore/ChangeLog15
-rw-r--r--third_party/WebKit/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm2
-rw-r--r--third_party/WebKit/Source/WebCore/bindings/scripts/CodeGeneratorV8.pm2
-rw-r--r--third_party/WebKit/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp2
-rw-r--r--third_party/WebKit/Source/WebCore/bindings/scripts/test/V8/V8TestObj.cpp2
30 files changed, 184 insertions, 134 deletions
diff --git a/third_party/WebKit/LayoutTests/ChangeLog b/third_party/WebKit/LayoutTests/ChangeLog
index 2696fcb..f8ad8d3 100644
--- a/third_party/WebKit/LayoutTests/ChangeLog
+++ b/third_party/WebKit/LayoutTests/ChangeLog
@@ -1,3 +1,38 @@
+2011-06-20 Mark Pilgrim <pilgrim@chromium.org>
+
+ Reviewed by Adam Barth.
+
+ IDL generator should throw TypeError instead of SyntaxError on not enough arguments
+ https://bugs.webkit.org/show_bug.cgi?id=63011
+
+ To align with WebIDL, we should throw TypeError whenever a function
+ is called with missing required arguments.
+
+ * fast/canvas/canvas-overloads-drawImageFromRect-expected.txt:
+ * fast/canvas/canvas-overloads-fillText-expected.txt:
+ * fast/canvas/canvas-overloads-strokeText-expected.txt:
+ * fast/canvas/script-tests/canvas-overloads-drawImageFromRect.js:
+ * fast/canvas/script-tests/canvas-overloads-fillText.js:
+ * fast/canvas/script-tests/canvas-overloads-strokeText.js:
+ * fast/canvas/webgl/data-view-test-expected.txt:
+ * http/tests/xmlhttprequest/exceptions-expected.txt:
+ * platform/chromium-mac/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt:
+ * platform/chromium-win/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt:
+ * svg/dom/SVGAngle-expected.txt:
+ * svg/dom/SVGColor-expected.txt:
+ * svg/dom/SVGLength-expected.txt:
+ * svg/dom/SVGLengthList-basics-expected.txt:
+ * svg/dom/SVGMatrix-expected.txt:
+ * svg/dom/SVGNumberList-basics-expected.txt:
+ * svg/dom/SVGPaint-expected.txt:
+ * svg/dom/SVGPoint-expected.txt:
+ * svg/dom/SVGPointList-basics-expected.txt:
+ * svg/dom/SVGStringList-basics-expected.txt:
+ * svg/dom/SVGTransform-expected.txt:
+ * svg/dom/SVGTransformList-basics-expected.txt:
+ * svg/dom/SVGTransformList-expected.txt:
+ * svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt:
+
2011-05-03 Martin Robinson <mrobinson@igalia.com>
Reviewed by Dirk Schulze.
diff --git a/third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-drawImageFromRect-expected.txt b/third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-drawImageFromRect-expected.txt
index 75bba0a..2f7da17 100644
--- a/third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-drawImageFromRect-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-drawImageFromRect-expected.txt
@@ -3,7 +3,7 @@ Test the behavior of CanvasRenderingContext2D.drawImageFromRect() when called wi
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-PASS ctx.drawImageFromRect() threw exception SyntaxError: Not enough arguments.
+PASS ctx.drawImageFromRect() threw exception TypeError: Not enough arguments.
PASS ctx.drawImageFromRect(imageElement) is undefined
PASS ctx.drawImageFromRect(imageElement, 0) is undefined
PASS ctx.drawImageFromRect(imageElement, 0, 0) is undefined
diff --git a/third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-fillText-expected.txt b/third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-fillText-expected.txt
index ebae81d..ccc5fa5 100644
--- a/third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-fillText-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-fillText-expected.txt
@@ -3,9 +3,9 @@ Test the behavior of CanvasRenderingContext2D.fillText() when called with differ
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-PASS ctx.fillText() threw exception SyntaxError: Not enough arguments.
-PASS ctx.fillText('moo') threw exception SyntaxError: Not enough arguments.
-PASS ctx.fillText('moo',0) threw exception SyntaxError: Not enough arguments.
+PASS ctx.fillText() threw exception TypeError: Not enough arguments.
+PASS ctx.fillText('moo') threw exception TypeError: Not enough arguments.
+PASS ctx.fillText('moo',0) threw exception TypeError: Not enough arguments.
PASS ctx.fillText('moo',0,0) is undefined
PASS ctx.fillText('moo',0,0,0) is undefined
PASS ctx.fillText('moo',0,0,0,0) is undefined
diff --git a/third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-strokeText-expected.txt b/third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-strokeText-expected.txt
index fa5c6f8..d217251 100644
--- a/third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-strokeText-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/canvas/canvas-overloads-strokeText-expected.txt
@@ -3,9 +3,9 @@ Test the behavior of CanvasRenderingContext2D.strokeText() when called with diff
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-PASS ctx.strokeText() threw exception SyntaxError: Not enough arguments.
-PASS ctx.strokeText('moo') threw exception SyntaxError: Not enough arguments.
-PASS ctx.strokeText('moo',0) threw exception SyntaxError: Not enough arguments.
+PASS ctx.strokeText() threw exception TypeError: Not enough arguments.
+PASS ctx.strokeText('moo') threw exception TypeError: Not enough arguments.
+PASS ctx.strokeText('moo',0) threw exception TypeError: Not enough arguments.
PASS ctx.strokeText('moo',0,0) is undefined
PASS ctx.strokeText('moo',0,0,0) is undefined
PASS ctx.strokeText('moo',0,0,0,0) is undefined
diff --git a/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-drawImageFromRect.js b/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-drawImageFromRect.js
index a32c8c5..dbc7edd 100644
--- a/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-drawImageFromRect.js
+++ b/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-drawImageFromRect.js
@@ -2,10 +2,10 @@ description("Test the behavior of CanvasRenderingContext2D.drawImageFromRect() w
var ctx = document.createElement('canvas').getContext('2d');
-var SyntaxError = "SyntaxError: Not enough arguments";
+var NotEnoughArguments = "TypeError: Not enough arguments";
var imageElement = document.createElement("img");
-shouldThrow("ctx.drawImageFromRect()", "SyntaxError");
+shouldThrow("ctx.drawImageFromRect()", "NotEnoughArguments");
shouldBe("ctx.drawImageFromRect(imageElement)", "undefined");
shouldBe("ctx.drawImageFromRect(imageElement, 0)", "undefined");
shouldBe("ctx.drawImageFromRect(imageElement, 0, 0)", "undefined");
diff --git a/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js b/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js
index 5429d3f..6597e18 100644
--- a/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js
+++ b/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js
@@ -2,12 +2,12 @@ description("Test the behavior of CanvasRenderingContext2D.fillText() when calle
var ctx = document.createElement('canvas').getContext('2d');
-var SyntaxError = "SyntaxError: Not enough arguments";
+var NotEnoughArguments = "TypeError: Not enough arguments";
var TypeError = "TypeError: Type error";
-shouldThrow("ctx.fillText()", "SyntaxError");
-shouldThrow("ctx.fillText('moo')", "SyntaxError");
-shouldThrow("ctx.fillText('moo',0)", "SyntaxError");
+shouldThrow("ctx.fillText()", "NotEnoughArguments");
+shouldThrow("ctx.fillText('moo')", "NotEnoughArguments");
+shouldThrow("ctx.fillText('moo',0)", "NotEnoughArguments");
shouldBe("ctx.fillText('moo',0,0)", "undefined");
shouldBe("ctx.fillText('moo',0,0,0)", "undefined");
shouldBe("ctx.fillText('moo',0,0,0,0)", "undefined");
diff --git a/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-strokeText.js b/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-strokeText.js
index 8cc9729..8a9079f 100644
--- a/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-strokeText.js
+++ b/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-strokeText.js
@@ -2,11 +2,11 @@ description("Test the behavior of CanvasRenderingContext2D.strokeText() when cal
var ctx = document.createElement('canvas').getContext('2d');
-var SyntaxError = "SyntaxError: Not enough arguments";
+var NotEnoughArguments = "TypeError: Not enough arguments";
-shouldThrow("ctx.strokeText()", "SyntaxError");
-shouldThrow("ctx.strokeText('moo')", "SyntaxError");
-shouldThrow("ctx.strokeText('moo',0)", "SyntaxError");
+shouldThrow("ctx.strokeText()", "NotEnoughArguments");
+shouldThrow("ctx.strokeText('moo')", "NotEnoughArguments");
+shouldThrow("ctx.strokeText('moo',0)", "NotEnoughArguments");
shouldBe("ctx.strokeText('moo',0,0)", "undefined");
shouldBe("ctx.strokeText('moo',0,0,0)", "undefined");
shouldBe("ctx.strokeText('moo',0,0,0,0)", "undefined");
diff --git a/third_party/WebKit/LayoutTests/fast/canvas/webgl/data-view-test-expected.txt b/third_party/WebKit/LayoutTests/fast/canvas/webgl/data-view-test-expected.txt
index ea84865..65b326f 100644
--- a/third_party/WebKit/LayoutTests/fast/canvas/webgl/data-view-test-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/canvas/webgl/data-view-test-expected.txt
@@ -301,12 +301,12 @@ PASS view.getFloat64(-9) threw exception Error: INDEX_SIZE_ERR: DOM Exception 1.
Test for wrong arguments passed to get methods
PASS view.getInt8() threw exception SyntaxError: Not enough arguments.
PASS view.getUint8() threw exception SyntaxError: Not enough arguments.
-PASS view.getInt16() threw exception SyntaxError: Not enough arguments.
-PASS view.getUint16() threw exception SyntaxError: Not enough arguments.
-PASS view.getInt32() threw exception SyntaxError: Not enough arguments.
-PASS view.getUint32() threw exception SyntaxError: Not enough arguments.
-PASS view.getFloat32() threw exception SyntaxError: Not enough arguments.
-PASS view.getFloat64() threw exception SyntaxError: Not enough arguments.
+PASS view.getInt16() threw exception TypeError: Not enough arguments.
+PASS view.getUint16() threw exception TypeError: Not enough arguments.
+PASS view.getInt32() threw exception TypeError: Not enough arguments.
+PASS view.getUint32() threw exception TypeError: Not enough arguments.
+PASS view.getFloat32() threw exception TypeError: Not enough arguments.
+PASS view.getFloat64() threw exception TypeError: Not enough arguments.
Test for set methods that work
PASS view.setInt8(0, 0) is undefined.
@@ -791,20 +791,20 @@ PASS view.setFloat64(-9, 0) threw exception Error: INDEX_SIZE_ERR: DOM Exception
Test for wrong arguments passed to set methods
PASS view.setInt8() threw exception SyntaxError: Not enough arguments.
PASS view.setUint8() threw exception SyntaxError: Not enough arguments.
-PASS view.setInt16() threw exception SyntaxError: Not enough arguments.
-PASS view.setUint16() threw exception SyntaxError: Not enough arguments.
-PASS view.setInt32() threw exception SyntaxError: Not enough arguments.
-PASS view.setUint32() threw exception SyntaxError: Not enough arguments.
-PASS view.setFloat32() threw exception SyntaxError: Not enough arguments.
-PASS view.setFloat64() threw exception SyntaxError: Not enough arguments.
+PASS view.setInt16() threw exception TypeError: Not enough arguments.
+PASS view.setUint16() threw exception TypeError: Not enough arguments.
+PASS view.setInt32() threw exception TypeError: Not enough arguments.
+PASS view.setUint32() threw exception TypeError: Not enough arguments.
+PASS view.setFloat32() threw exception TypeError: Not enough arguments.
+PASS view.setFloat64() threw exception TypeError: Not enough arguments.
PASS view.setInt8(1) threw exception SyntaxError: Not enough arguments.
PASS view.setUint8(1) threw exception SyntaxError: Not enough arguments.
-PASS view.setInt16(1) threw exception SyntaxError: Not enough arguments.
-PASS view.setUint16(1) threw exception SyntaxError: Not enough arguments.
-PASS view.setInt32(1) threw exception SyntaxError: Not enough arguments.
-PASS view.setUint32(1) threw exception SyntaxError: Not enough arguments.
-PASS view.setFloat32(1) threw exception SyntaxError: Not enough arguments.
-PASS view.setFloat64(1) threw exception SyntaxError: Not enough arguments.
+PASS view.setInt16(1) threw exception TypeError: Not enough arguments.
+PASS view.setUint16(1) threw exception TypeError: Not enough arguments.
+PASS view.setInt32(1) threw exception TypeError: Not enough arguments.
+PASS view.setUint32(1) threw exception TypeError: Not enough arguments.
+PASS view.setFloat32(1) threw exception TypeError: Not enough arguments.
+PASS view.setFloat64(1) threw exception TypeError: Not enough arguments.
Test for indexing that should not work
PASS view[0] is undefined.
diff --git a/third_party/WebKit/LayoutTests/http/tests/xmlhttprequest/exceptions-expected.txt b/third_party/WebKit/LayoutTests/http/tests/xmlhttprequest/exceptions-expected.txt
index 8799236..fb34614 100644
--- a/third_party/WebKit/LayoutTests/http/tests/xmlhttprequest/exceptions-expected.txt
+++ b/third_party/WebKit/LayoutTests/http/tests/xmlhttprequest/exceptions-expected.txt
@@ -4,11 +4,11 @@ new XMLHttpRequest()
PASS: req.setRequestHeader("Foo", "bar") threw exception Error: INVALID_STATE_ERR: DOM Exception 11.
PASS: req.send(null) threw exception Error: INVALID_STATE_ERR: DOM Exception 11.
open()
-PASS: req.setRequestHeader() threw exception SyntaxError: Not enough arguments.
-PASS: req.setRequestHeader("Foo") threw exception SyntaxError: Not enough arguments.
+PASS: req.setRequestHeader() threw exception TypeError: Not enough arguments.
+PASS: req.setRequestHeader("Foo") threw exception TypeError: Not enough arguments.
PASS: req.status() threw exception Error: INVALID_STATE_ERR: DOM Exception 11.
PASS: req.statusText() threw exception Error: INVALID_STATE_ERR: DOM Exception 11.
send()
PASS: req.send(null) threw exception Error: INVALID_STATE_ERR: DOM Exception 11.
PASS: req.setRequestHeader("Foo", "bar") threw exception Error: INVALID_STATE_ERR: DOM Exception 11.
-PASS: req.getResponseHeader() threw exception SyntaxError: Not enough arguments.
+PASS: req.getResponseHeader() threw exception TypeError: Not enough arguments.
diff --git a/third_party/WebKit/LayoutTests/platform/chromium-mac/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt b/third_party/WebKit/LayoutTests/platform/chromium-mac/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt
index bab98e9..3bb3684 100644
--- a/third_party/WebKit/LayoutTests/platform/chromium-mac/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/chromium-mac/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt
@@ -3,7 +3,7 @@ Tests that an exception is thrown if we try to get a pathSeg for a length out of
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-PASS path.pathSegList.initialize(); threw exception SyntaxError: Not enough arguments.
+PASS path.pathSegList.initialize(); threw exception TypeError: Not enough arguments.
PASS path.getPathSegAtLength(0) is 0
PASS path.insertItemBefore(null, 0) threw exception TypeError: Object #<SVGPathElement> has no method 'insertItemBefore'.
PASS path.replaceItem(null, 0) threw exception TypeError: Object #<SVGPathElement> has no method 'replaceItem'.
diff --git a/third_party/WebKit/LayoutTests/platform/chromium-win/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt b/third_party/WebKit/LayoutTests/platform/chromium-win/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt
index bab98e9..3bb3684 100644
--- a/third_party/WebKit/LayoutTests/platform/chromium-win/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/chromium-win/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt
@@ -3,7 +3,7 @@ Tests that an exception is thrown if we try to get a pathSeg for a length out of
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-PASS path.pathSegList.initialize(); threw exception SyntaxError: Not enough arguments.
+PASS path.pathSegList.initialize(); threw exception TypeError: Not enough arguments.
PASS path.getPathSegAtLength(0) is 0
PASS path.insertItemBefore(null, 0) threw exception TypeError: Object #<SVGPathElement> has no method 'insertItemBefore'.
PASS path.replaceItem(null, 0) threw exception TypeError: Object #<SVGPathElement> has no method 'replaceItem'.
diff --git a/third_party/WebKit/LayoutTests/svg/dom/SVGAngle-expected.txt b/third_party/WebKit/LayoutTests/svg/dom/SVGAngle-expected.txt
index 3cc890e..b257ba9 100644
--- a/third_party/WebKit/LayoutTests/svg/dom/SVGAngle-expected.txt
+++ b/third_party/WebKit/LayoutTests/svg/dom/SVGAngle-expected.txt
@@ -17,7 +17,7 @@ PASS angle.convertToSpecifiedUnits(5) threw exception Error: NOT_SUPPORTED_ERR:
PASS angle.convertToSpecifiedUnits('aString') threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
PASS angle.convertToSpecifiedUnits(angle) threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
PASS angle.convertToSpecifiedUnits(svgElement) threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
-PASS angle.convertToSpecifiedUnits() threw exception SyntaxError: Not enough arguments.
+PASS angle.convertToSpecifiedUnits() threw exception TypeError: Not enough arguments.
PASS angle.unitType is SVGAngle.SVG_ANGLETYPE_UNSPECIFIED
Check valid arguments for 'convertToSpecifiedUnits', that should only modify the 'valueAsString'
@@ -46,7 +46,7 @@ Check invalid arguments for 'newValueSpecifiedUnits'
PASS angle.newValueSpecifiedUnits(SVGAngle.SVG_ANGLETYPE_UNKNOWN, 50) threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
PASS angle.newValueSpecifiedUnits(-1, 50) threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
PASS angle.newValueSpecifiedUnits(5, 50) threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
-PASS angle.newValueSpecifiedUnits(SVGAngle.SVG_ANGLETYPE_DEG) threw exception SyntaxError: Not enough arguments.
+PASS angle.newValueSpecifiedUnits(SVGAngle.SVG_ANGLETYPE_DEG) threw exception TypeError: Not enough arguments.
PASS angle.newValueSpecifiedUnits(SVGAngle.SVG_ANGLETYPE_DEG, 'aString') is undefined.
PASS angle.value is NaN
PASS angle.newValueSpecifiedUnits(SVGAngle.SVG_ANGLETYPE_DEG, 0) is undefined.
@@ -54,14 +54,14 @@ PASS angle.newValueSpecifiedUnits(SVGAngle.SVG_ANGLETYPE_DEG, angle) is undefine
PASS angle.value is NaN
PASS angle.newValueSpecifiedUnits(SVGAngle.SVG_ANGLETYPE_DEG, svgElement) is undefined.
PASS angle.value is NaN
-PASS angle.newValueSpecifiedUnits(SVGAngle.SVG_ANGLETYPE_DEG) threw exception SyntaxError: Not enough arguments.
+PASS angle.newValueSpecifiedUnits(SVGAngle.SVG_ANGLETYPE_DEG) threw exception TypeError: Not enough arguments.
PASS angle.newValueSpecifiedUnits('aString', 4) threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
PASS angle.newValueSpecifiedUnits(angle, 4) threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
PASS angle.newValueSpecifiedUnits(svgElement, 4) threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
PASS angle.newValueSpecifiedUnits('aString', 'aString') threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
PASS angle.newValueSpecifiedUnits(angle, angle) threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
PASS angle.newValueSpecifiedUnits(svgElement, svgElement) threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
-PASS angle.newValueSpecifiedUnits() threw exception SyntaxError: Not enough arguments.
+PASS angle.newValueSpecifiedUnits() threw exception TypeError: Not enough arguments.
PASS angle.unitType is SVGAngle.SVG_ANGLETYPE_DEG
Check valid arguments for 'newValueSpecifiedUnits', that should only modify the 'valueAsString'
diff --git a/third_party/WebKit/LayoutTests/svg/dom/SVGColor-expected.txt b/third_party/WebKit/LayoutTests/svg/dom/SVGColor-expected.txt
index f43017c..8fb325b 100644
--- a/third_party/WebKit/LayoutTests/svg/dom/SVGColor-expected.txt
+++ b/third_party/WebKit/LayoutTests/svg/dom/SVGColor-expected.txt
@@ -19,8 +19,8 @@ PASS stopColor.setColor(null, null, null) threw exception Error: SVG_INVALID_VAL
PASS stopColor.setColor(SVGColor.SVG_COLORTYPE_RGBCOLOR, svgElement, ''); threw exception Error: SVG_INVALID_VALUE_ERR: DOM SVG Exception 1.
PASS stopColor.setColor(SVGColor.SVG_COLORTYPE_RGBCOLOR, '', '') threw exception Error: SVG_INVALID_VALUE_ERR: DOM SVG Exception 1.
PASS stopColor.setColor(SVGColor.SVG_COLORTYPE_CURRENTCOLOR + 1, '', ''); threw exception Error: SVG_WRONG_TYPE_ERR: DOM SVG Exception 0.
-PASS stopColor.setColor() threw exception SyntaxError: Not enough arguments.
-PASS stopColor.setColor(stopColor) threw exception SyntaxError: Not enough arguments.
+PASS stopColor.setColor() threw exception TypeError: Not enough arguments.
+PASS stopColor.setColor(stopColor) threw exception TypeError: Not enough arguments.
Try assigning to the readonly colorType property, which silently fails
PASS stopColor.colorType = SVGColor.SVG_COLORTYPE_UNKKNOWN; is undefined.
diff --git a/third_party/WebKit/LayoutTests/svg/dom/SVGLength-expected.txt b/third_party/WebKit/LayoutTests/svg/dom/SVGLength-expected.txt
index 7f8ce63..45826cc 100644
--- a/third_party/WebKit/LayoutTests/svg/dom/SVGLength-expected.txt
+++ b/third_party/WebKit/LayoutTests/svg/dom/SVGLength-expected.txt
@@ -41,7 +41,7 @@ PASS length.value is NaN
PASS length.newValueSpecifiedUnits(SVGLength.SVG_LENGTHTYPE_PX, 0) is undefined.
PASS length.newValueSpecifiedUnits(SVGLength.SVG_LENGTHTYPE_PX, svgElement) is undefined.
PASS length.value is NaN
-PASS length.newValueSpecifiedUnits(SVGLength.SVG_LENGTHTYPE_PX) threw exception SyntaxError: Not enough arguments.
+PASS length.newValueSpecifiedUnits(SVGLength.SVG_LENGTHTYPE_PX) threw exception TypeError: Not enough arguments.
PASS length.newValueSpecifiedUnits('aString', 4) threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
PASS length.newValueSpecifiedUnits(length, 4) threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
PASS length.newValueSpecifiedUnits(svgElement, 4) threw exception Error: NOT_SUPPORTED_ERR: DOM Exception 9.
diff --git a/third_party/WebKit/LayoutTests/svg/dom/SVGLengthList-basics-expected.txt b/third_party/WebKit/LayoutTests/svg/dom/SVGLengthList-basics-expected.txt
index 6a6ecd7..3743912 100644
--- a/third_party/WebKit/LayoutTests/svg/dom/SVGLengthList-basics-expected.txt
+++ b/third_party/WebKit/LayoutTests/svg/dom/SVGLengthList-basics-expected.txt
@@ -24,10 +24,10 @@ PASS text1.x.baseVal.getItem(text1) is text1.x.baseVal.getItem(0)
PASS text1.x.baseVal.getItem(null) is text1.x.baseVal.getItem(0)
Test uncommon arguments for insertItemBefore()
-PASS text1.x.baseVal.insertItemBefore(30) threw exception SyntaxError: Not enough arguments.
-PASS text1.x.baseVal.insertItemBefore('aString') threw exception SyntaxError: Not enough arguments.
-PASS text1.x.baseVal.insertItemBefore(text1) threw exception SyntaxError: Not enough arguments.
-PASS text1.x.baseVal.insertItemBefore(null) threw exception SyntaxError: Not enough arguments.
+PASS text1.x.baseVal.insertItemBefore(30) threw exception TypeError: Not enough arguments.
+PASS text1.x.baseVal.insertItemBefore('aString') threw exception TypeError: Not enough arguments.
+PASS text1.x.baseVal.insertItemBefore(text1) threw exception TypeError: Not enough arguments.
+PASS text1.x.baseVal.insertItemBefore(null) threw exception TypeError: Not enough arguments.
PASS text1.x.baseVal.insertItemBefore(text1.x.baseVal.getItem(1), 'aString') is text1.x.baseVal.getItem(0)
PASS text1.x.baseVal.numberOfItems is 3
PASS text1.x.baseVal.getItem(0).value is 1000
@@ -67,10 +67,10 @@ PASS text1.x.baseVal.getItem(3).value is 4
PASS text1.getAttribute('x') is "1 2 3 4"
Test uncommon arguments for replaceItem()
-PASS text1.x.baseVal.replaceItem(30) threw exception SyntaxError: Not enough arguments.
-PASS text1.x.baseVal.replaceItem('aString') threw exception SyntaxError: Not enough arguments.
-PASS text1.x.baseVal.replaceItem(text1) threw exception SyntaxError: Not enough arguments.
-PASS text1.x.baseVal.replaceItem(null) threw exception SyntaxError: Not enough arguments.
+PASS text1.x.baseVal.replaceItem(30) threw exception TypeError: Not enough arguments.
+PASS text1.x.baseVal.replaceItem('aString') threw exception TypeError: Not enough arguments.
+PASS text1.x.baseVal.replaceItem(text1) threw exception TypeError: Not enough arguments.
+PASS text1.x.baseVal.replaceItem(null) threw exception TypeError: Not enough arguments.
PASS text1.x.baseVal.replaceItem(30, 0) threw exception TypeError: Type error.
PASS text1.x.baseVal.replaceItem('aString', 0) threw exception TypeError: Type error.
PASS text1.x.baseVal.replaceItem(text1, 0) threw exception TypeError: Type error.
diff --git a/third_party/WebKit/LayoutTests/svg/dom/SVGMatrix-expected.txt b/third_party/WebKit/LayoutTests/svg/dom/SVGMatrix-expected.txt
index 43e84b2..42d7106 100644
--- a/third_party/WebKit/LayoutTests/svg/dom/SVGMatrix-expected.txt
+++ b/third_party/WebKit/LayoutTests/svg/dom/SVGMatrix-expected.txt
@@ -90,18 +90,18 @@ PASS matrix.e is 0
PASS matrix.f is 0
Check calling 'multiply' with invalid arguments
-PASS matrix.multiply() threw exception SyntaxError: Not enough arguments.
+PASS matrix.multiply() threw exception TypeError: Not enough arguments.
PASS matrix.multiply(true) threw exception TypeError: Type error.
PASS matrix.multiply(2) threw exception TypeError: Type error.
PASS matrix.multiply('aString') threw exception TypeError: Type error.
PASS matrix.multiply(svgElement) threw exception TypeError: Type error.
Check calling 'translate' with invalid arguments
-PASS matrix.translate() threw exception SyntaxError: Not enough arguments.
-PASS matrix.translate(true) threw exception SyntaxError: Not enough arguments.
-PASS matrix.translate(2) threw exception SyntaxError: Not enough arguments.
-PASS matrix.translate('aString') threw exception SyntaxError: Not enough arguments.
-PASS matrix.translate(svgElement) threw exception SyntaxError: Not enough arguments.
+PASS matrix.translate() threw exception TypeError: Not enough arguments.
+PASS matrix.translate(true) threw exception TypeError: Not enough arguments.
+PASS matrix.translate(2) threw exception TypeError: Not enough arguments.
+PASS matrix.translate('aString') threw exception TypeError: Not enough arguments.
+PASS matrix.translate(svgElement) threw exception TypeError: Not enough arguments.
PASS matrix.translate('aString', 'aString') is non-null.
PASS matrix.translate(svgElement, svgElement) is non-null.
PASS matrix.translate(2, 'aString') is non-null.
@@ -110,16 +110,16 @@ PASS matrix.translate('aString', 2) is non-null.
PASS matrix.translate(svgElement, 2) is non-null.
Check calling 'scale' with invalid arguments
-PASS matrix.scale() threw exception SyntaxError: Not enough arguments.
+PASS matrix.scale() threw exception TypeError: Not enough arguments.
PASS matrix.scale('aString') is non-null.
PASS matrix.scale(svgElement) is non-null.
Check calling 'scaleNonUniform' with invalid arguments
-PASS matrix.scaleNonUniform() threw exception SyntaxError: Not enough arguments.
-PASS matrix.scaleNonUniform(true) threw exception SyntaxError: Not enough arguments.
-PASS matrix.scaleNonUniform(2) threw exception SyntaxError: Not enough arguments.
-PASS matrix.scaleNonUniform('aString') threw exception SyntaxError: Not enough arguments.
-PASS matrix.scaleNonUniform(svgElement) threw exception SyntaxError: Not enough arguments.
+PASS matrix.scaleNonUniform() threw exception TypeError: Not enough arguments.
+PASS matrix.scaleNonUniform(true) threw exception TypeError: Not enough arguments.
+PASS matrix.scaleNonUniform(2) threw exception TypeError: Not enough arguments.
+PASS matrix.scaleNonUniform('aString') threw exception TypeError: Not enough arguments.
+PASS matrix.scaleNonUniform(svgElement) threw exception TypeError: Not enough arguments.
PASS matrix.scaleNonUniform('aString', 'aString') is non-null.
PASS matrix.scaleNonUniform(svgElement, svgElement) is non-null.
PASS matrix.scaleNonUniform(2, 'aString') is non-null.
@@ -128,16 +128,16 @@ PASS matrix.scaleNonUniform('aString', 2) is non-null.
PASS matrix.scaleNonUniform(svgElement, 2) is non-null.
Check calling 'rotate' with invalid arguments
-PASS matrix.rotate() threw exception SyntaxError: Not enough arguments.
+PASS matrix.rotate() threw exception TypeError: Not enough arguments.
PASS matrix.rotate('aString') is non-null.
PASS matrix.rotate(svgElement) is non-null.
Check calling 'rotateFromVector' with invalid arguments
-PASS matrix.rotateFromVector() threw exception SyntaxError: Not enough arguments.
-PASS matrix.rotateFromVector(true) threw exception SyntaxError: Not enough arguments.
-PASS matrix.rotateFromVector(2) threw exception SyntaxError: Not enough arguments.
-PASS matrix.rotateFromVector('aString') threw exception SyntaxError: Not enough arguments.
-PASS matrix.rotateFromVector(svgElement) threw exception SyntaxError: Not enough arguments.
+PASS matrix.rotateFromVector() threw exception TypeError: Not enough arguments.
+PASS matrix.rotateFromVector(true) threw exception TypeError: Not enough arguments.
+PASS matrix.rotateFromVector(2) threw exception TypeError: Not enough arguments.
+PASS matrix.rotateFromVector('aString') threw exception TypeError: Not enough arguments.
+PASS matrix.rotateFromVector(svgElement) threw exception TypeError: Not enough arguments.
PASS matrix.rotateFromVector('aString', 'aString') is non-null.
PASS matrix.rotateFromVector(svgElement, svgElement) is non-null.
PASS matrix.rotateFromVector(2, 'aString') is non-null.
@@ -146,12 +146,12 @@ PASS matrix.rotateFromVector('aString', 2) is non-null.
PASS matrix.rotateFromVector(svgElement, 2) is non-null.
Check calling 'skewX' with invalid arguments
-PASS matrix.skewX() threw exception SyntaxError: Not enough arguments.
+PASS matrix.skewX() threw exception TypeError: Not enough arguments.
PASS matrix.skewX('aString') is non-null.
PASS matrix.skewX(svgElement) is non-null.
Check calling 'skewY' with invalid arguments
-PASS matrix.skewY() threw exception SyntaxError: Not enough arguments.
+PASS matrix.skewY() threw exception TypeError: Not enough arguments.
PASS matrix.skewY('aString') is non-null.
PASS matrix.skewY(svgElement) is non-null.
PASS successfullyParsed is true
diff --git a/third_party/WebKit/LayoutTests/svg/dom/SVGNumberList-basics-expected.txt b/third_party/WebKit/LayoutTests/svg/dom/SVGNumberList-basics-expected.txt
index 714da38..d347812 100644
--- a/third_party/WebKit/LayoutTests/svg/dom/SVGNumberList-basics-expected.txt
+++ b/third_party/WebKit/LayoutTests/svg/dom/SVGNumberList-basics-expected.txt
@@ -21,10 +21,10 @@ PASS text1.rotate.baseVal.getItem(text1) is text1.rotate.baseVal.getItem(0)
PASS text1.rotate.baseVal.getItem(null) is text1.rotate.baseVal.getItem(0)
Test uncommon arguments for insertItemBefore()
-PASS text1.rotate.baseVal.insertItemBefore(30) threw exception SyntaxError: Not enough arguments.
-PASS text1.rotate.baseVal.insertItemBefore('aString') threw exception SyntaxError: Not enough arguments.
-PASS text1.rotate.baseVal.insertItemBefore(text1) threw exception SyntaxError: Not enough arguments.
-PASS text1.rotate.baseVal.insertItemBefore(null) threw exception SyntaxError: Not enough arguments.
+PASS text1.rotate.baseVal.insertItemBefore(30) threw exception TypeError: Not enough arguments.
+PASS text1.rotate.baseVal.insertItemBefore('aString') threw exception TypeError: Not enough arguments.
+PASS text1.rotate.baseVal.insertItemBefore(text1) threw exception TypeError: Not enough arguments.
+PASS text1.rotate.baseVal.insertItemBefore(null) threw exception TypeError: Not enough arguments.
PASS text1.rotate.baseVal.insertItemBefore(text1.rotate.baseVal.getItem(1), 'aString') is text1.rotate.baseVal.getItem(0)
PASS text1.rotate.baseVal.numberOfItems is 3
PASS text1.rotate.baseVal.getItem(0).value is 180
@@ -64,10 +64,10 @@ PASS text1.rotate.baseVal.getItem(3).value is 4
PASS text1.getAttribute('rotate') is "1 2 3 4"
Test uncommon arguments for replaceItem()
-PASS text1.rotate.baseVal.replaceItem(30) threw exception SyntaxError: Not enough arguments.
-PASS text1.rotate.baseVal.replaceItem('aString') threw exception SyntaxError: Not enough arguments.
-PASS text1.rotate.baseVal.replaceItem(text1) threw exception SyntaxError: Not enough arguments.
-PASS text1.rotate.baseVal.replaceItem(null) threw exception SyntaxError: Not enough arguments.
+PASS text1.rotate.baseVal.replaceItem(30) threw exception TypeError: Not enough arguments.
+PASS text1.rotate.baseVal.replaceItem('aString') threw exception TypeError: Not enough arguments.
+PASS text1.rotate.baseVal.replaceItem(text1) threw exception TypeError: Not enough arguments.
+PASS text1.rotate.baseVal.replaceItem(null) threw exception TypeError: Not enough arguments.
PASS text1.rotate.baseVal.replaceItem(30, 0) threw exception TypeError: Type error.
PASS text1.rotate.baseVal.replaceItem('aString', 0) threw exception TypeError: Type error.
PASS text1.rotate.baseVal.replaceItem(text1, 0) threw exception TypeError: Type error.
diff --git a/third_party/WebKit/LayoutTests/svg/dom/SVGPaint-expected.txt b/third_party/WebKit/LayoutTests/svg/dom/SVGPaint-expected.txt
index 8afb150..ed9768b 100644
--- a/third_party/WebKit/LayoutTests/svg/dom/SVGPaint-expected.txt
+++ b/third_party/WebKit/LayoutTests/svg/dom/SVGPaint-expected.txt
@@ -19,15 +19,15 @@ PASS document.defaultView.getComputedStyle(rectElement).fill is "#008000"
Try invalid arguments for setPaint()
PASS fillPaint.setPaint(null, null, null, null) threw exception Error: SVG_INVALID_VALUE_ERR: DOM SVG Exception 1.
PASS fillPaint.setPaint(SVGPaint.SVG_PAINTTYPE_RGBCOLOR, svgElement, '', ''); threw exception Error: SVG_INVALID_VALUE_ERR: DOM SVG Exception 1.
-PASS fillPaint.setPaint(SVGPaint.SVG_PAINTTYPE_RGBCOLOR, '', '') threw exception SyntaxError: Not enough arguments.
+PASS fillPaint.setPaint(SVGPaint.SVG_PAINTTYPE_RGBCOLOR, '', '') threw exception TypeError: Not enough arguments.
PASS fillPaint.setPaint(SVGPaint.SVG_PAINTTYPE_RGBCOLOR_ICCCOLOR + 1, '', '', ''); threw exception Error: SVG_WRONG_TYPE_ERR: DOM SVG Exception 0.
PASS fillPaint.setPaint(SVGPaint.SVG_PAINTTYPE_NONE - 1, '', '', ''); threw exception Error: SVG_WRONG_TYPE_ERR: DOM SVG Exception 0.
PASS fillPaint.setPaint(SVGPaint.SVG_PAINTTYPE_URI + 1, '', '', ''); threw exception Error: SVG_WRONG_TYPE_ERR: DOM SVG Exception 0.
-PASS fillPaint.setPaint() threw exception SyntaxError: Not enough arguments.
-PASS fillPaint.setPaint(fillPaint) threw exception SyntaxError: Not enough arguments.
+PASS fillPaint.setPaint() threw exception TypeError: Not enough arguments.
+PASS fillPaint.setPaint(fillPaint) threw exception TypeError: Not enough arguments.
Try invalid arguments for setUri()
-PASS fillPaint.setUri() threw exception SyntaxError: Not enough arguments.
+PASS fillPaint.setUri() threw exception TypeError: Not enough arguments.
Try assigning to the readonly paintType property, which silently fails
PASS fillPaint.paintType = SVGPaint.SVG_PAINTTYPE_UNKKNOWN; is undefined.
diff --git a/third_party/WebKit/LayoutTests/svg/dom/SVGPoint-expected.txt b/third_party/WebKit/LayoutTests/svg/dom/SVGPoint-expected.txt
index a638f98..b526660 100644
--- a/third_party/WebKit/LayoutTests/svg/dom/SVGPoint-expected.txt
+++ b/third_party/WebKit/LayoutTests/svg/dom/SVGPoint-expected.txt
@@ -28,7 +28,7 @@ PASS newPoint.x is 60
PASS newPoint.y is 210
Check invalid arguments for 'matrixTransform'
-PASS point.matrixTransform() threw exception SyntaxError: Not enough arguments.
+PASS point.matrixTransform() threw exception TypeError: Not enough arguments.
PASS point.matrixTransform(-1) threw exception TypeError: Type error.
PASS point.matrixTransform(5) threw exception TypeError: Type error.
PASS point.matrixTransform('aString') threw exception TypeError: Type error.
diff --git a/third_party/WebKit/LayoutTests/svg/dom/SVGPointList-basics-expected.txt b/third_party/WebKit/LayoutTests/svg/dom/SVGPointList-basics-expected.txt
index 4edb981..f60a95d 100644
--- a/third_party/WebKit/LayoutTests/svg/dom/SVGPointList-basics-expected.txt
+++ b/third_party/WebKit/LayoutTests/svg/dom/SVGPointList-basics-expected.txt
@@ -40,10 +40,10 @@ PASS poly1.points.getItem(poly1) is poly1.points.getItem(0)
PASS poly1.points.getItem(null) is poly1.points.getItem(0)
Test uncommon arguments for insertItemBefore()
-PASS poly1.points.insertItemBefore(30) threw exception SyntaxError: Not enough arguments.
-PASS poly1.points.insertItemBefore('aString') threw exception SyntaxError: Not enough arguments.
-PASS poly1.points.insertItemBefore(poly1) threw exception SyntaxError: Not enough arguments.
-PASS poly1.points.insertItemBefore(null) threw exception SyntaxError: Not enough arguments.
+PASS poly1.points.insertItemBefore(30) threw exception TypeError: Not enough arguments.
+PASS poly1.points.insertItemBefore('aString') threw exception TypeError: Not enough arguments.
+PASS poly1.points.insertItemBefore(poly1) threw exception TypeError: Not enough arguments.
+PASS poly1.points.insertItemBefore(null) threw exception TypeError: Not enough arguments.
PASS dumpPoint(poly1.points.insertItemBefore(poly1.points.getItem(1), 'aString')) is "x=100 y=0"
PASS poly1.points.numberOfItems is 4
PASS dumpPoint(poly1.points.getItem(0)) is "x=100 y=0"
@@ -77,9 +77,9 @@ PASS poly1.points.insertItemBefore(poly1, 0) threw exception TypeError: Type err
PASS poly1.points.insertItemBefore(null, 0) threw exception Error: SVG_WRONG_TYPE_ERR: DOM SVG Exception 0.
Test uncommon arguments for replaceItem()
-PASS poly1.points.replaceItem(30) threw exception SyntaxError: Not enough arguments.
-PASS poly1.points.replaceItem('aString') threw exception SyntaxError: Not enough arguments.
-PASS poly1.points.replaceItem(poly1) threw exception SyntaxError: Not enough arguments.
+PASS poly1.points.replaceItem(30) threw exception TypeError: Not enough arguments.
+PASS poly1.points.replaceItem('aString') threw exception TypeError: Not enough arguments.
+PASS poly1.points.replaceItem(poly1) threw exception TypeError: Not enough arguments.
PASS poly1.points.replaceItem(null, 0) threw exception Error: SVG_WRONG_TYPE_ERR: DOM SVG Exception 0.
PASS poly1.points.replaceItem('aString', 0) threw exception TypeError: Type error.
PASS poly1.points.replaceItem(poly1, 0) threw exception TypeError: Type error.
diff --git a/third_party/WebKit/LayoutTests/svg/dom/SVGStringList-basics-expected.txt b/third_party/WebKit/LayoutTests/svg/dom/SVGStringList-basics-expected.txt
index 16bd979..728c297 100644
--- a/third_party/WebKit/LayoutTests/svg/dom/SVGStringList-basics-expected.txt
+++ b/third_party/WebKit/LayoutTests/svg/dom/SVGStringList-basics-expected.txt
@@ -31,10 +31,10 @@ PASS text1.requiredFeatures.getItem(text1) is text1.requiredFeatures.getItem(0)
PASS text1.requiredFeatures.getItem(null) is text1.requiredFeatures.getItem(0)
Test uncommon arguments for insertItemBefore()
-PASS text1.requiredFeatures.insertItemBefore(30) threw exception SyntaxError: Not enough arguments.
-PASS text1.requiredFeatures.insertItemBefore('aString') threw exception SyntaxError: Not enough arguments.
-PASS text1.requiredFeatures.insertItemBefore(text1) threw exception SyntaxError: Not enough arguments.
-PASS text1.requiredFeatures.insertItemBefore(null) threw exception SyntaxError: Not enough arguments.
+PASS text1.requiredFeatures.insertItemBefore(30) threw exception TypeError: Not enough arguments.
+PASS text1.requiredFeatures.insertItemBefore('aString') threw exception TypeError: Not enough arguments.
+PASS text1.requiredFeatures.insertItemBefore(text1) threw exception TypeError: Not enough arguments.
+PASS text1.requiredFeatures.insertItemBefore(null) threw exception TypeError: Not enough arguments.
PASS text1.requiredFeatures.insertItemBefore(text1.requiredFeatures.getItem(1), 'aString') threw exception Error: INDEX_SIZE_ERR: DOM Exception 1.
PASS text1.requiredFeatures.insertItemBefore(text1.requiredFeatures.getItem(1), text1) threw exception Error: INDEX_SIZE_ERR: DOM Exception 1.
PASS text1.requiredFeatures.insertItemBefore(text1.requiredFeatures.getItem(1), null) threw exception Error: INDEX_SIZE_ERR: DOM Exception 1.
@@ -76,9 +76,9 @@ PASS text1.requiredFeatures.getItem(3) is "4"
PASS text1.getAttribute('requiredFeatures') is "1 2 3 4"
Test uncommon arguments for replaceItem() - part 1
-PASS text1.requiredFeatures.replaceItem(30) threw exception SyntaxError: Not enough arguments.
-PASS text1.requiredFeatures.replaceItem('aString') threw exception SyntaxError: Not enough arguments.
-PASS text1.requiredFeatures.replaceItem(text1) threw exception SyntaxError: Not enough arguments.
+PASS text1.requiredFeatures.replaceItem(30) threw exception TypeError: Not enough arguments.
+PASS text1.requiredFeatures.replaceItem('aString') threw exception TypeError: Not enough arguments.
+PASS text1.requiredFeatures.replaceItem(text1) threw exception TypeError: Not enough arguments.
PASS text1.requiredFeatures.replaceItem(null, 0) is "null"
PASS text1.requiredFeatures.numberOfItems is 4
PASS text1.requiredFeatures.getItem(0) is "null"
diff --git a/third_party/WebKit/LayoutTests/svg/dom/SVGTransform-expected.txt b/third_party/WebKit/LayoutTests/svg/dom/SVGTransform-expected.txt
index d5c8c5d..c17facb 100644
--- a/third_party/WebKit/LayoutTests/svg/dom/SVGTransform-expected.txt
+++ b/third_party/WebKit/LayoutTests/svg/dom/SVGTransform-expected.txt
@@ -49,7 +49,7 @@ PASS transform.matrix.e is 0
PASS transform.matrix.f is 0
Check passing invalid arguments to 'setMatrix'
-PASS transform.setMatrix() threw exception SyntaxError: Not enough arguments.
+PASS transform.setMatrix() threw exception TypeError: Not enough arguments.
PASS transform.setMatrix(transform) threw exception TypeError: Type error.
PASS transform.setMatrix(svgElement) threw exception TypeError: Type error.
PASS transform.setMatrix('aString') threw exception TypeError: Type error.
@@ -57,10 +57,10 @@ PASS transform.setMatrix(1) threw exception TypeError: Type error.
PASS transform.setMatrix(false) threw exception TypeError: Type error.
Check passing invalid arguments to 'setTranslate'
-PASS transform.setTranslate() threw exception SyntaxError: Not enough arguments.
-PASS transform.setTranslate(transform) threw exception SyntaxError: Not enough arguments.
-PASS transform.setTranslate(svgElement) threw exception SyntaxError: Not enough arguments.
-PASS transform.setTranslate('aString') threw exception SyntaxError: Not enough arguments.
+PASS transform.setTranslate() threw exception TypeError: Not enough arguments.
+PASS transform.setTranslate(transform) threw exception TypeError: Not enough arguments.
+PASS transform.setTranslate(svgElement) threw exception TypeError: Not enough arguments.
+PASS transform.setTranslate('aString') threw exception TypeError: Not enough arguments.
PASS transform.setTranslate(1, transform) is undefined.
PASS transform.setTranslate(1, svgElement) is undefined.
PASS transform.setTranslate(1, 'aString') is undefined.
@@ -72,10 +72,10 @@ PASS transform.setTranslate(svgElement, svgElement) is undefined.
PASS transform.setTranslate('aString', 'aString') is undefined.
Check passing invalid arguments to 'setScale'
-PASS transform.setScale() threw exception SyntaxError: Not enough arguments.
-PASS transform.setScale(transform) threw exception SyntaxError: Not enough arguments.
-PASS transform.setScale(svgElement) threw exception SyntaxError: Not enough arguments.
-PASS transform.setScale('aString') threw exception SyntaxError: Not enough arguments.
+PASS transform.setScale() threw exception TypeError: Not enough arguments.
+PASS transform.setScale(transform) threw exception TypeError: Not enough arguments.
+PASS transform.setScale(svgElement) threw exception TypeError: Not enough arguments.
+PASS transform.setScale('aString') threw exception TypeError: Not enough arguments.
PASS transform.setScale(1, transform) is undefined.
PASS transform.setScale(1, svgElement) is undefined.
PASS transform.setScale(1, 'aString') is undefined.
@@ -87,25 +87,25 @@ PASS transform.setScale(svgElement, svgElement) is undefined.
PASS transform.setScale('aString', 'aString') is undefined.
Check passing invalid arguments to 'setRotate'
-PASS transform.setRotate() threw exception SyntaxError: Not enough arguments.
-PASS transform.setRotate(transform) threw exception SyntaxError: Not enough arguments.
-PASS transform.setRotate(svgElement) threw exception SyntaxError: Not enough arguments.
-PASS transform.setRotate('aString') threw exception SyntaxError: Not enough arguments.
-PASS transform.setRotate(1, transform) threw exception SyntaxError: Not enough arguments.
-PASS transform.setRotate(1, svgElement) threw exception SyntaxError: Not enough arguments.
-PASS transform.setRotate(1, 'aString') threw exception SyntaxError: Not enough arguments.
+PASS transform.setRotate() threw exception TypeError: Not enough arguments.
+PASS transform.setRotate(transform) threw exception TypeError: Not enough arguments.
+PASS transform.setRotate(svgElement) threw exception TypeError: Not enough arguments.
+PASS transform.setRotate('aString') threw exception TypeError: Not enough arguments.
+PASS transform.setRotate(1, transform) threw exception TypeError: Not enough arguments.
+PASS transform.setRotate(1, svgElement) threw exception TypeError: Not enough arguments.
+PASS transform.setRotate(1, 'aString') threw exception TypeError: Not enough arguments.
PASS transform.setRotate(1, 1, transform) is undefined.
PASS transform.setRotate(1, 1, svgElement) is undefined.
PASS transform.setRotate(1, 1, 'aString') is undefined.
Check passing invalid arguments to 'setSkewX'
-PASS transform.setSkewX() threw exception SyntaxError: Not enough arguments.
+PASS transform.setSkewX() threw exception TypeError: Not enough arguments.
PASS transform.setSkewX(transform) is undefined.
PASS transform.setSkewX(svgElement) is undefined.
PASS transform.setSkewX('aString') is undefined.
Check passing invalid arguments to 'setSkewY'
-PASS transform.setSkewY() threw exception SyntaxError: Not enough arguments.
+PASS transform.setSkewY() threw exception TypeError: Not enough arguments.
PASS transform.setSkewY(transform) is undefined.
PASS transform.setSkewY(svgElement) is undefined.
PASS transform.setSkewY('aString') is undefined.
diff --git a/third_party/WebKit/LayoutTests/svg/dom/SVGTransformList-basics-expected.txt b/third_party/WebKit/LayoutTests/svg/dom/SVGTransformList-basics-expected.txt
index abd1462..bbf82e8 100644
--- a/third_party/WebKit/LayoutTests/svg/dom/SVGTransformList-basics-expected.txt
+++ b/third_party/WebKit/LayoutTests/svg/dom/SVGTransformList-basics-expected.txt
@@ -22,10 +22,10 @@ PASS circle1.transform.baseVal.getItem(circle1) is circle1.transform.baseVal.get
PASS circle1.transform.baseVal.getItem(null) is circle1.transform.baseVal.getItem(0)
Test uncommon arguments for insertItemBefore()
-PASS circle1.transform.baseVal.insertItemBefore(30) threw exception SyntaxError: Not enough arguments.
-PASS circle1.transform.baseVal.insertItemBefore('aString') threw exception SyntaxError: Not enough arguments.
-PASS circle1.transform.baseVal.insertItemBefore(circle1) threw exception SyntaxError: Not enough arguments.
-PASS circle1.transform.baseVal.insertItemBefore(null) threw exception SyntaxError: Not enough arguments.
+PASS circle1.transform.baseVal.insertItemBefore(30) threw exception TypeError: Not enough arguments.
+PASS circle1.transform.baseVal.insertItemBefore('aString') threw exception TypeError: Not enough arguments.
+PASS circle1.transform.baseVal.insertItemBefore(circle1) threw exception TypeError: Not enough arguments.
+PASS circle1.transform.baseVal.insertItemBefore(null) threw exception TypeError: Not enough arguments.
PASS circle1.transform.baseVal.insertItemBefore(circle1.transform.baseVal.getItem(1), 'aString') is circle1.transform.baseVal.getItem(0)
PASS circle1.transform.baseVal.numberOfItems is 2
PASS dumpTransform(circle1.transform.baseVal.getItem(0)) is "type=SVG_TRANSFORM_TRANSLATE matrix=[1.0 0.0 0.0 1.0 10.0 10.0]"
@@ -61,10 +61,10 @@ PASS dumpTransform(circle1.transform.baseVal.getItem(3)) is "type=SVG_TRANSFORM_
PASS circle1.getAttribute('transform') is "rotate(90) scale(2 2) translate(10 10) skewX(45)"
Test uncommon arguments for replaceItem()
-PASS circle1.transform.baseVal.replaceItem(30) threw exception SyntaxError: Not enough arguments.
-PASS circle1.transform.baseVal.replaceItem('aString') threw exception SyntaxError: Not enough arguments.
-PASS circle1.transform.baseVal.replaceItem(circle1) threw exception SyntaxError: Not enough arguments.
-PASS circle1.transform.baseVal.replaceItem(null) threw exception SyntaxError: Not enough arguments.
+PASS circle1.transform.baseVal.replaceItem(30) threw exception TypeError: Not enough arguments.
+PASS circle1.transform.baseVal.replaceItem('aString') threw exception TypeError: Not enough arguments.
+PASS circle1.transform.baseVal.replaceItem(circle1) threw exception TypeError: Not enough arguments.
+PASS circle1.transform.baseVal.replaceItem(null) threw exception TypeError: Not enough arguments.
PASS circle1.transform.baseVal.replaceItem(30, 0) threw exception TypeError: Type error.
PASS circle1.transform.baseVal.replaceItem('aString', 0) threw exception TypeError: Type error.
PASS circle1.transform.baseVal.replaceItem(circle1, 0) threw exception TypeError: Type error.
diff --git a/third_party/WebKit/LayoutTests/svg/dom/SVGTransformList-expected.txt b/third_party/WebKit/LayoutTests/svg/dom/SVGTransformList-expected.txt
index 0157aaa..7ac93f6 100644
--- a/third_party/WebKit/LayoutTests/svg/dom/SVGTransformList-expected.txt
+++ b/third_party/WebKit/LayoutTests/svg/dom/SVGTransformList-expected.txt
@@ -5,7 +5,7 @@ On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
Check passing invalid arguments to 'createSVGTransformFromMatrix'
-PASS transform.createSVGTransformFromMatrix() threw exception SyntaxError: Not enough arguments.
+PASS transform.createSVGTransformFromMatrix() threw exception TypeError: Not enough arguments.
PASS transform.createSVGTransformFromMatrix(svgElement.createSVGTransform()) threw exception TypeError: Type error.
PASS transform.createSVGTransformFromMatrix(svgElement) threw exception TypeError: Type error.
PASS transform.createSVGTransformFromMatrix('aString') threw exception TypeError: Type error.
diff --git a/third_party/WebKit/LayoutTests/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt b/third_party/WebKit/LayoutTests/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt
index bef59ec..d3a9621 100644
--- a/third_party/WebKit/LayoutTests/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt
+++ b/third_party/WebKit/LayoutTests/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt
@@ -3,7 +3,7 @@ Tests that an exception is thrown if we try to get a pathSeg for a length out of
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-PASS path.pathSegList.initialize(); threw exception SyntaxError: Not enough arguments.
+PASS path.pathSegList.initialize(); threw exception TypeError: Not enough arguments.
PASS path.getPathSegAtLength(0) is 0
PASS path.insertItemBefore(null, 0) threw exception TypeError: 'undefined' is not a function (evaluating 'path.insertItemBefore(null, 0)').
PASS path.replaceItem(null, 0) threw exception TypeError: 'undefined' is not a function (evaluating 'path.replaceItem(null, 0)').
diff --git a/third_party/WebKit/Source/WebCore/ChangeLog b/third_party/WebKit/Source/WebCore/ChangeLog
index e7dea49..3456380 100644
--- a/third_party/WebKit/Source/WebCore/ChangeLog
+++ b/third_party/WebKit/Source/WebCore/ChangeLog
@@ -1,3 +1,18 @@
+2011-06-20 Mark Pilgrim <pilgrim@chromium.org>
+
+ Reviewed by Adam Barth.
+
+ IDL generator should throw TypeError instead of SyntaxError on not enough arguments
+ https://bugs.webkit.org/show_bug.cgi?id=63011
+
+ To align with WebIDL, we should throw TypeError whenever a function
+ is called with missing required arguments.
+
+ * bindings/scripts/CodeGeneratorJS.pm:
+ * bindings/scripts/CodeGeneratorV8.pm:
+ * bindings/scripts/test/V8/V8TestObj.cpp:
+ (WebCore::TestObjInternal::methodThatRequiresAllArgsAndThrowsCallback):
+
2011-05-03 Martin Robinson <mrobinson@igalia.com>
Reviewed by Dirk Schulze.
diff --git a/third_party/WebKit/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm b/third_party/WebKit/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm
index 4d7f41f..f01cdac 100644
--- a/third_party/WebKit/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm
+++ b/third_party/WebKit/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm
@@ -1948,7 +1948,7 @@ sub GenerateImplementation
{
push(@implContent, " if (exec->argumentCount() < $numMandatoryParams)\n");
if ($requiresAllArguments eq "Raise") {
- push(@implContent, " return throwVMError(exec, createSyntaxError(exec, \"Not enough arguments\"));\n");
+ push(@implContent, " return throwVMError(exec, createTypeError(exec, \"Not enough arguments\"));\n");
} else {
push(@implContent, " return JSValue::encode(jsUndefined());\n");
}
diff --git a/third_party/WebKit/Source/WebCore/bindings/scripts/CodeGeneratorV8.pm b/third_party/WebKit/Source/WebCore/bindings/scripts/CodeGeneratorV8.pm
index 59950aa..fdc6c22 100644
--- a/third_party/WebKit/Source/WebCore/bindings/scripts/CodeGeneratorV8.pm
+++ b/third_party/WebKit/Source/WebCore/bindings/scripts/CodeGeneratorV8.pm
@@ -1259,7 +1259,7 @@ END
}
push(@implContentDecls, " if (args.Length() < $numMandatoryParams)\n");
if ($requiresAllArguments eq "Raise") {
- push(@implContentDecls, " return throwError(\"Not enough arguments\", V8Proxy::SyntaxError);\n");
+ push(@implContentDecls, " return throwError(\"Not enough arguments\", V8Proxy::TypeError);\n");
} else {
push(@implContentDecls, " return v8::Handle<v8::Value>();\n");
}
diff --git a/third_party/WebKit/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp b/third_party/WebKit/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp
index d05b719..3ac6fc7 100644
--- a/third_party/WebKit/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp
+++ b/third_party/WebKit/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp
@@ -1036,7 +1036,7 @@ EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionMethodThatRequiresAllArgs
ASSERT_GC_OBJECT_INHERITS(castedThis, &JSTestObj::s_info);
TestObj* imp = static_cast<TestObj*>(castedThis->impl());
if (exec->argumentCount() < 2)
- return throwVMError(exec, createSyntaxError(exec, "Not enough arguments"));
+ return throwVMError(exec, createTypeError(exec, "Not enough arguments"));
ExceptionCode ec = 0;
const String& strArg(ustringToString(exec->argument(0).toString(exec)));
if (exec->hadException())
diff --git a/third_party/WebKit/Source/WebCore/bindings/scripts/test/V8/V8TestObj.cpp b/third_party/WebKit/Source/WebCore/bindings/scripts/test/V8/V8TestObj.cpp
index 4239ad2..5cee745 100644
--- a/third_party/WebKit/Source/WebCore/bindings/scripts/test/V8/V8TestObj.cpp
+++ b/third_party/WebKit/Source/WebCore/bindings/scripts/test/V8/V8TestObj.cpp
@@ -698,7 +698,7 @@ static v8::Handle<v8::Value> methodThatRequiresAllArgsAndThrowsCallback(const v8
{
INC_STATS("DOM.TestObj.methodThatRequiresAllArgsAndThrows");
if (args.Length() < 2)
- return throwError("Not enough arguments", V8Proxy::SyntaxError);
+ return throwError("Not enough arguments", V8Proxy::TypeError);
TestObj* imp = V8TestObj::toNative(args.Holder());
ExceptionCode ec = 0;
{