Repository navigation
fix(gpui): keep rejected in scope for the external-texture draw - #11
Conversation
The flag was declared inside the device borrow, but the partial-upload return runs after that borrow ends, so Windows failed to compile.
|
Caution PR Summary Skipped - Monthly Quota ExceededPR summary skipped as you have reached the free tier limit of 50 PR summaries per month. Please upgrade to a paid plan for MatterAI. Current Plan: Free Tier Upgrade your plan on the console here: https://app.matterai.so/ai-code-reviews?tab=Billing |
Qodo reviews are paused for this user.Troubleshooting steps vary by plan Learn more → On a Teams plan? Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center? |
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. Note Currently processing new changes in this PR. This may take a few minutes, please wait... ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Essentials Run ID: 📒 Files selected for processing (1)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Copilot review overview
🟢 Approval recommended
The scoping-only fix resolves the compile error without changing behavior.
Review effort: Lite
Findings: None
What changed in this PR
Fixes a Windows compilation error by widening rejected’s scope in external-texture drawing.
Changes:
- Moves
rejectedoutside the device-borrow block. - Preserves existing partial-upload behavior.
| File | Description |
|---|---|
crates/gpui_windows/src/directx_renderer.rs |
Fixes variable scoping in external-texture drawing. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
What this fixes
The Windows build of
gpui_windowsfailed to compile. InDirectXRenderer's external-texture draw,rejectedwas declared inside the device-borrow block, but the partial-upload check that reads it runs after that block ends. The fix moves the declaration above the block. There is no behaviour change on any platform.Why merge it now
Cherry Pick already pins this commit (
d31a784): cherrypickmainhas pointed itscherrypick-zedsubmodule here since877920ef("point cherrypick-zed at the Windows external-texture compile fix"). The commit exists only on this branch, so deleting or force-pushing the branch would leave the pinned submodule commit unfetchable for fresh clones and CI. Merging it intomainmakes the pin reachable from the default branch.Checks
crates/gpui_windows/src/directx_renderer.rs, +4/−1.main(6397a12), so the merge is a fast-forward with no conflicts.mainand CodeCraftersLLC/cherrypick#132 already check out this commit as their submodule. Their PR CI does not compile the Windows renderer, so the Windows build itself was not re-verified here.🤖 Generated with Claude Code
Note
Low Risk
Single-line scoping fix in Windows rendering with no intended runtime behavior change.
Overview
Fixes a Windows compile error in
draw_external_frame: therejectedflag was declared inside the scoped block that borrows the D3D device, but the function still reads it after that block when deciding whether to returnExternalTextureUpload::Partial.The change moves
let mut rejected = falseabove the device block and adds a short comment. Upload validation still setsrejectedinside the block; the post-draw partial-upload path is unchanged in intent—only the variable’s lifetime is widened so the crate builds.Reviewed by Cursor Bugbot for commit d31a784. Bugbot is set up for automated code reviews on this repo. Configure here.
Summary by cubic
Fixes the Windows compile failure in
gpui_windows's external-texture draw by moving therejectedflag above the device-borrow block, where the partial-upload check reads it after the borrow ends. No behavior change on any platform.Merge note
cherrypick-zedsubmodule pins this commit, which exists only on this branch; merging intomainkeeps the pin reachable for fresh clones and CI.Written for commit d31a784. Summary will update on new commits.