Skip to content

Fix enableMeasurement() comment to name measureContent() - #60578

Open
YevheniiKotyrlo wants to merge 1 commit into
react:mainfrom
YevheniiKotyrlo:fix/enable-measurement-comment-names-measure-content
Open

YevheniiKotyrlo wants to merge 1 commit into
react:mainfrom
YevheniiKotyrlo:fix/enable-measurement-comment-names-measure-content

Conversation

@YevheniiKotyrlo

@YevheniiKotyrlo YevheniiKotyrlo commented Dec 4, 2026 •

Copy link
Copy Markdown
Contributor

Summary:

The comment on YogaLayoutableShadowNode::enableMeasurement() says it connects the Yoga node's measure function with LayoutableShadowNode::measure(). The function it connects, yogaNodeMeasureCallbackConnector, calls the node's measureContent() (YogaLayoutableShadowNode.cpp#L981-L983), not its measure(). The comment now names measureContent().

Related: #60571 adds enableBaseline() beside enableMeasurement(), its comment in the same shape; #60572 adds getLayoutMargins() to the same header; #60581 passes the source revision to the shouldNewRevisionDirtyMeasurement() call in completeClone(); #60583 dirties a node connected by enableMeasurement() alone when a new revision invalidates its measurement or the font scale changes. All four merge with this without conflict. #59048 and #59139 add tests to ViewTest.cpp and share no file with this.

Changelog:

[INTERNAL] [FIXED] - Name measureContent() in the comment on YogaLayoutableShadowNode::enableMeasurement()

Test Plan:

Comment-only change. clang-format --dry-run --Werror on YogaLayoutableShadowNode.h reports the same lines on main and on this branch, none in the changed comment (clang-format 23.1.4; the repository pins 21.1.2). The C++ API snapshots in scripts/cxx-api/api-snapshots strip doc comments (scripts/cxx-api/README.md), so none changes.

The measure function enableMeasurement() connects,
yogaNodeMeasureCallbackConnector, calls
LayoutableShadowNode::measureContent(), not measure().

Signed-off-by: YevheniiKotyrlo <44449990+YevheniiKotyrlo@users.noreply.github.com>

This branch has not been deployed

No deployments
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.

1 participant