Revision: 21028
Author: [email protected]
Date: Mon Apr 28 15:57:25 2014 UTC
Log: Revert "PromiseThen should ignore non-function parameters."
Wrong Blink test expectations, need to fix later.
[email protected]
BUG=
Review URL: https://codereview.chromium.org/251813004
http://code.google.com/p/v8/source/detail?r=21028
Modified:
/branches/bleeding_edge/src/promise.js
/branches/bleeding_edge/test/mjsunit/es6/promises.js
/branches/bleeding_edge/test/promises-aplus/promises-aplus.status
=======================================
--- /branches/bleeding_edge/src/promise.js Mon Apr 28 15:19:15 2014 UTC
+++ /branches/bleeding_edge/src/promise.js Mon Apr 28 15:57:25 2014 UTC
@@ -215,9 +215,9 @@
function PromiseThen(onResolve, onReject) {
onResolve =
- IS_SPEC_FUNCTION(onResolve) ? onResolve : PromiseIdResolveHandler;
+ IS_NULL_OR_UNDEFINED(onResolve) ? PromiseIdResolveHandler : onResolve;
onReject =
- IS_SPEC_FUNCTION(onReject) ? onReject : PromiseIdRejectHandler;
+ IS_NULL_OR_UNDEFINED(onReject) ? PromiseIdRejectHandler : onReject;
var that = this;
var constructor = this.constructor;
return %_CallFunction(
=======================================
--- /branches/bleeding_edge/test/mjsunit/es6/promises.js Mon Apr 28
15:19:15 2014 UTC
+++ /branches/bleeding_edge/test/mjsunit/es6/promises.js Mon Apr 28
15:57:25 2014 UTC
@@ -396,30 +396,6 @@
assertAsyncRan()
})();
-(function() {
- var deferred = Promise.defer()
- var p1 = deferred.promise
- var p2 = p1.then(1, 2)
- p2.then(
- function(x) { assertAsync(x === 5, "then/resolve-non-function") },
- assertUnreachable
- )
- deferred.resolve(5)
- assertAsyncRan()
-})();
-
-(function() {
- var deferred = Promise.defer()
- var p1 = deferred.promise
- var p2 = p1.then(1, 2)
- p2.then(
- assertUnreachable,
- function(x) { assertAsync(x === 5, "then/reject-non-function") }
- )
- deferred.reject(5)
- assertAsyncRan()
-})();
-
(function() {
var deferred = Promise.defer()
var p1 = deferred.promise
=======================================
--- /branches/bleeding_edge/test/promises-aplus/promises-aplus.status Mon
Apr 28 15:19:15 2014 UTC
+++ /branches/bleeding_edge/test/promises-aplus/promises-aplus.status Mon
Apr 28 15:57:25 2014 UTC
@@ -28,5 +28,7 @@
[
[ALWAYS, {
+ # http://crbug.com/347455
+ '2.2.7': FAIL
}], # ALWAYS
]
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.