Skip to content

Name function type parameters and use exact-by-default objects - #2198

Open
SamChou19815 wants to merge 1 commit into
mainfrom
export-D130549170
Open

SamChou19815 wants to merge 1 commit into
mainfrom
export-D130549170

Conversation

@SamChou19815

Copy link
Copy Markdown
Member

Summary:
Name the remaining function type parameters and remove redundant exact object delimiters. The runtime code is unchanged.

Changelog: [Internal]

Differential Revision: D130549170

Summary:
Name the remaining function type parameters and remove redundant exact object delimiters. The runtime code is unchanged.

Changelog: [Internal]

Differential Revision: D130549170
@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Nov 8, 2026
@meta-codesync

meta-codesync Bot commented Nov 8, 2026

Copy link
Copy Markdown
Contributor

@SamChou19815 has exported this pull request. If you are a Meta employee, you can view the originating Diff in D130549170.

@github-actions

github-actions Bot commented Nov 8, 2026

Copy link
Copy Markdown

Metro review: Looks good

Risk: low · Commit: fea0c2a · 5 commands run

This PR removes {| |} delimiters from the flow-typed/jest.js libdef and names one function type parameter inside a Flow comment in the Haste worker; the diff confirms the runtime code is unchanged. No problems found, but flow check, the main check for a types-only change, was not run in this review (see not_run), so rely on CI for it. The description's "remaining" is slightly broad: crawlers/__tests__/node-test.js still has unnamed string => string types, which has no effect on behavior.

No findings.

Verified
  • ✅ yarn -s eslint flow-typed/jest.js packages/metro-file-map/src/plugins/haste/worker.js — 0 errors. flow-typed/jest.js matches an ignore pattern, so only worker.js was actually linted.
  • ✅ yarn -s prettier --check flow-typed/jest.js packages/metro-file-map/src/plugins/haste/worker.js
  • ✅ yarn -s jest --no-watchman packages/metro-file-map/src/plugins — 7 suites, 64 tests passed.
  • ✅ git diff -w d233537c48bb2d2507817d17e03bfc3bc6febce5 HEAD -- packages — The only change under packages/ is the type annotation inside a /*: */ comment in worker.js.
  • ✅ node_modules/.bin/flow version — Flow 0.338.0. This only reports the version; it does not typecheck.

Not run: yarn typecheck (flow check) did not run: the command was denied because it required a permission approval that isn't available in this session, so the change is not verified under Flow. Exact-by-default was checked only statically: .flowconfig has no exact_by_default override, and Flow 0.338's default is exact, from general knowledge of Flow rather than a run. Benchmarks were skipped because the only change to shipped source is inside a comment. Windows was not tested, as nothing here is platform-specific. yarn verify-api-snapshots was not run because no exports changed.

Automated review by Claude. Advisory only: it never approves or blocks, and a maintainer makes the call.

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

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. meta-exported needs-meta-import

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant