Helper functions to conveniently create a promise that is resolved to the given value (or rejected with the given reason).
promise_resolve(value)
promise_reject(reason)
A value, or promise, that the new promise should be resolved to. This expression will be lazily evaluated, and if evaluating the expression raises an error, then the new promise will be rejected with that error as the reason.
An error message string, or error object.