Skip to content

[pull] master from foundry-rs:master#1088

Merged
pull[bot] merged 3 commits into
antazoey:masterfrom
foundry-rs:master
Jul 22, 2026
Merged

[pull] master from foundry-rs:master#1088
pull[bot] merged 3 commits into
antazoey:masterfrom
foundry-rs:master

Conversation

@pull

@pull pull Bot commented Jul 22, 2026

Copy link
Copy Markdown

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

mattsse and others added 3 commits July 22, 2026 19:51
* feat(primitives): add variant predicates

Expose documented const helpers across Foundry network and transaction enums, including feature-gated Optimism variants. Keep standard typed transaction predicates on Typed2718 where appropriate and migrate exact single-variant checks to the shared API.

* fix(primitives): satisfy clippy use-self lint

Use the enum's Self type in the Optimism transaction trait implementation so the workspace use_self lint remains warning-free.

---------

Co-authored-by: mattsse <19890894+mattsse@users.noreply.github.com>
* feat(lint): detect balance reentrancy

Extend the existing reentrancy analysis to track locals derived from address(this).balance and report reentrant calls followed by stale balance guards.

Register the high-severity lint and add documentation plus focused true- and false-path UI coverage.

* fix(lint): harden balance reentrancy

Track native self-balance values across casts, tuples, helper boundaries, operand ordering, and loop control flow. Resolve external calls semantically while preserving view, static, storage, and stipend-capped exclusions.

* fix(lint): address reentrancy reviews

Require fresh and stale balances on opposite comparison operands, model standard state-lock guards across effective entry points, restore bounded recursive entry analysis, and account for value-call gas stipends.

* fix(lint): preserve balance flow facts

Carry stale-balance comparison and boolean path provenance through helper returns, compound assignments, and control-flow joins. This avoids false positives on complementary conditions without hiding reachable callback paths.

* fix(lint): track self address aliases

Preserve address(this) provenance through locals, tuples, helper and modifier parameters, and branch-correlated call paths. Invalidate aliases on observable writes and assembly reassignment.

* fix(lint): track balance expression paths

Propagate path constraints and self-address provenance through short-circuit expressions and helper returns so balance reentrancy diagnostics follow feasible paths.

* fix(lint): complete balance reentrancy flow

Track internal function-pointer targets through assignments and control-flow joins so helper callbacks remain visible to the balance analysis. Recognize standard lock modifiers whose sole placeholder is nested in an unconditional block.

Amp-Thread-ID: https://ampcode.com/threads/T-019f896c-fd1a-745b-be37-de6016df1dbb
Co-authored-by: Amp <amp@ampcode.com>

---------

Co-authored-by: Mablr <59505383+mablr@users.noreply.github.com>
Co-authored-by: Amp <amp@ampcode.com>
@pull pull Bot locked and limited conversation to collaborators Jul 22, 2026
@pull pull Bot added the ⤵️ pull label Jul 22, 2026
@pull
pull Bot merged commit 05a7547 into antazoey:master Jul 22, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants