Conversation
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has enabled the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. |
just ast to update all generated files.rest fields of ArrayAssignmentTarget and ObjectAssignmentTarget
CodSpeed Instrumentation Performance ReportMerging #12698 will not alter performanceComparing Summary
|
|
@copilot You missed running for |
Fixed! I ran Warning Firewall rules blocked me from connecting to one or more addressesI tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
Co-authored-by: Dunqing <29533304+Dunqing@users.noreply.github.com>
894d584 to
d4eeffb
Compare
rest fields of ArrayAssignmentTarget and ObjectAssignmentTargetrest fields of ArrayAssignmentTarget and ObjectAssignmentTarget
Pure refactor. Follow-on after #12698. Use `AstBuilder::alloc_*` methods to shorten code.
Summary
This PR optimizes memory usage by boxing the
restfields inArrayAssignmentTargetandObjectAssignmentTargetstructs, reducing their size from 40 bytes to 28 bytes each (12 byte reduction per struct).Changes
AST Definition Changes:
ArrayAssignmentTarget.restfromOption<AssignmentTargetRest<'a>>toOption<Box<'a, AssignmentTargetRest<'a>>>ObjectAssignmentTarget.restfromOption<AssignmentTargetRest<'a>>toOption<Box<'a, AssignmentTargetRest<'a>>>Generated Code Updates:
assert_layouts.rs(40 → 28 bytes)Parser Updates:
p.ast.alloc()Transformer Updates:
Memory Impact
Option<AssignmentTargetRest>: 24 bytesOption<Box<AssignmentTargetRest>>: 8 bytesThis follows the same pattern already used for
restfields inArrayPattern,ObjectPattern, andFormalParametersstructs.Testing
Fixes #12697
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.