areLValuesLastUsedByScope() — react Function Reference
Architecture documentation for the areLValuesLastUsedByScope() function in MergeReactiveScopesThatInvalidateTogether.ts from the react codebase.
Entity Profile
Dependency Diagram
graph TD 34751151_352b_2ab2_756a_e87e6700e5d1["areLValuesLastUsedByScope()"] 006711fe_6949_9be8_4726_2031284f3328["MergeReactiveScopesThatInvalidateTogether.ts"] 34751151_352b_2ab2_756a_e87e6700e5d1 -->|defined in| 006711fe_6949_9be8_4726_2031284f3328 11690004_c468_3b6b_f07f_36a6501f870a["visitBlock()"] 11690004_c468_3b6b_f07f_36a6501f870a -->|calls| 34751151_352b_2ab2_756a_e87e6700e5d1 2ac731a7_1748_e943_7a74_4b9c344e4398["log()"] 34751151_352b_2ab2_756a_e87e6700e5d1 -->|calls| 2ac731a7_1748_e943_7a74_4b9c344e4398 style 34751151_352b_2ab2_756a_e87e6700e5d1 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
compiler/packages/babel-plugin-react-compiler/src/ReactiveScopes/MergeReactiveScopesThatInvalidateTogether.ts lines 422–435
function areLValuesLastUsedByScope(
scope: ReactiveScope,
lvalues: Set<DeclarationId>,
lastUsage: Map<DeclarationId, InstructionId>,
): boolean {
for (const lvalue of lvalues) {
const lastUsedAt = lastUsage.get(lvalue)!;
if (lastUsedAt >= scope.range.end) {
log(` lvalue ${lvalue} used after scope @${scope.id}, cannot merge`);
return false;
}
}
return true;
}
Domain
Subdomains
Calls
Called By
Source
Frequently Asked Questions
What does areLValuesLastUsedByScope() do?
areLValuesLastUsedByScope() is a function in the react codebase, defined in compiler/packages/babel-plugin-react-compiler/src/ReactiveScopes/MergeReactiveScopesThatInvalidateTogether.ts.
Where is areLValuesLastUsedByScope() defined?
areLValuesLastUsedByScope() is defined in compiler/packages/babel-plugin-react-compiler/src/ReactiveScopes/MergeReactiveScopesThatInvalidateTogether.ts at line 422.
What does areLValuesLastUsedByScope() call?
areLValuesLastUsedByScope() calls 1 function(s): log.
What calls areLValuesLastUsedByScope()?
areLValuesLastUsedByScope() is called by 1 function(s): visitBlock.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free