diff --git a/index.bs b/index.bs index a337e31..49e8de7 100644 --- a/index.bs +++ b/index.bs @@ -210,27 +210,27 @@ When writing such specifications, it's convenient to be able to refer to common
new Promise((resolve, reject) => { ... })
, using the initial value of the Promise
constructor. Here ...
stands in for code that saves the value of resolve
and reject
for later use by the shorthands under [[#shorthand-manipulating]].
+"A new promise" gives a new, initialized-but-unresolved promise object to manipulate further. It is equivalent to calling new Promise((resolve, reject) => { ... })
, using the initial value of the Promise
constructor. Here ...
stands in for code that saves the value of resolve
and reject
for later use by the shorthands under [[#shorthand-manipulating]].
-"A promise resolved with x" or "x resolved as a promise" is shorthand for the result of Promise.resolve(x)
, using the initial value of Promise.resolve
.
+"A promise resolved with x" or "x resolved as a promise" is shorthand for the result of Promise.resolve(x)
, using the initial value of Promise.resolve
.
-"A promise rejected with r" is shorthand for the result of Promise.reject(r)
, using the initial value of Promise.reject
.
+"A promise rejected with r" is shorthand for the result of Promise.reject(r)
, using the initial value of Promise.reject
.
resolve
function from creating p
, with argument x
.
+"Resolve p with x" is shorthand for calling a previously-stored resolve
function from creating p
, with argument x
.
-"Reject p with r" is shorthand for calling a previously-stored reject
function from creating p
, with argument r
.
+"Reject p with r" is shorthand for calling a previously-stored reject
function from creating p
, with argument r
.
If the algorithm using these shorthands is running in parallel, the shorthands queue a task on p's relevant settings object's responsible event loop to call the stored function.
p.then(onFulfilled)
, with the successive nested steps comprising the onFulfilled
function, and using the initial value of Promise.prototype.then
. The steps then have access to onFulfilled
's argument as v.
+"Upon fulfillment of p with value v" is shorthand for calling p.then(onFulfilled)
, with the successive nested steps comprising the onFulfilled
function, and using the initial value of Promise.prototype.then
. The steps then have access to onFulfilled
's argument as v.
-"Upon rejection of p with reason r" is shorthand for calling p.then(undefined, onRejected)
, with the successive nested steps comprising the onRejected
function, and using the initial value of Promise.prototype.then
. The steps then have access to onRejected
's argument as r.
+"Upon rejection of p with reason r" is shorthand for calling p.then(undefined, onRejected)
, with the successive nested steps comprising the onRejected
function, and using the initial value of Promise.prototype.then
. The steps then have access to onRejected
's argument as r.
-"Transforming p with a fulfillment and/or rejection handler" is shorthand for calling p.then(fulfillmentHandler, rejectionHandler)
, using the initial value of Promise.prototype.then
.
+"Transforming p with a fulfillment and/or rejection handler" is shorthand for calling p.then(fulfillmentHandler, rejectionHandler)
, using the initial value of Promise.prototype.then
.