-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
use consistent phrasing for comparing string values #2794
Comments
I like "is the same string value" personally. We could |
We could also use the phrase within |
Also, "is the empty String" should remain. |
Related: #2405 Since strings don't carry identity, "is" should be fine. Also because of this, we can do things like |
Discussed at the editor call today. "is" or "=" would be preferable as long as we've made it clear that strings do not carry identity, so I'm going to try to fix #2405 first. We could probably then use this phrasing for all values which are declared not to have identity. |
@gibson042 asks what our conventions should be for comparing strings in https://github.com/tc39/ecma262/pull/2721/files/#r890585298.
I think "equals" is indeed bad, but we have many options available:
SameValue
SameValueNonNumeric
Let's pick something and make it consistent.
The text was updated successfully, but these errors were encountered: