-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Fix typos in comments of JSCJSValue.h #25696
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 typos in comments of JSCJSValue.h #25696
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this comment is meant to be interpreted as zero indexed. Documenting that seems reasonable though. Maybe "All non-numeric (bool, null, undefined) immediates have bit 1 (zero indexed) set."?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the review. However, there are sections in other comments as well where the bit ordering is represented as 0-indexed. So how about making a similar documenting to those part? This would help clarify that the bits are 0-indexed in the content of the subsequent comments as well.
Line 454~458:
* These values have the following properties:
* - Bit 1 (0-indexed) is set (OtherTag) for all four values, allowing real pointers to be
* quickly distinguished from all immediate values, including these invalid pointers.
* - With bit 3 (0-indexed) masked out (UndefinedTag), Undefined and Null share the
* same value, allowing null & undefined to be quickly detected.
Line 485 as reviewed.
// All non-numeric (bool, null, undefined) immediates have bit 1 (0-indexed) set.
The expression 0-indexed are being used in Source/JavaScriptCore/runtime/JSBigInt.cpp
kmiller68
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think your commit comment is duplicated.
|
I apologize for the mistake in handling Git. I have now combined the commit messages into one. Could you please take a look? |
|
EWS run on previous version of this PR (hash 6904fa5) Details
|
|
EWS run on previous version of this PR (hash 45e390d) Details
|
|
EWS run on previous version of this PR (hash 223b739) Details
|
|
EWS run on current version of this PR (hash 9dc1c21) Details |
kmiller68
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
r=me.
|
Safe-Merge-Queue: Build #14672. |
https://bugs.webkit.org/show_bug.cgi?id=270775 Reviewed by Keith Miller. It is the second bit which is set for non-numeric immediates and the second bit is bit 1. * Source/JavaScriptCore/runtime/JSCJSValue.h: Canonical link: https://commits.webkit.org/275951@main
|
Committed 275951@main (b2b0e19): https://commits.webkit.org/275951@main Reviewed commits have been landed. Closing PR #25696 and removing active labels. |
b2b0e19
9dc1c21