Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: rename deferred.status -> state #1055

Merged
merged 1 commit into from
Jul 22, 2021
Merged

Conversation

kt3k
Copy link
Member

@kt3k kt3k commented Jul 22, 2021

As pointed in #1047 (comment) by @kitsonk, ecma262 spec calls this property of promise [[PromiseState]] (ref: https://tc39.es/ecma262/#sec-fulfillpromise). This PR follows that convention to reduce confusions in the future, and renames the property to '.state'

This PR also makes the property 'readonly' (both in typings and runtime)

cc @lowlighter

@kt3k kt3k requested a review from kitsonk July 22, 2021 09:02
@caspervonb
Copy link
Contributor

The V8 API also refers to this as the promise state so SGTM.

Copy link
Contributor

@kitsonk kitsonk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@kt3k kt3k merged commit bf73521 into denoland:main Jul 22, 2021
@kt3k kt3k deleted the fix/deferred-state branch July 22, 2021 10:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants