Handle ambiguous effects more reliably and emit diagnostics for these - #1379
Open
lionel- wants to merge 10 commits into
Open
Handle ambiguous effects more reliably and emit diagnostics for these#1379lionel- wants to merge 10 commits into
lionel- wants to merge 10 commits into
Conversation
lionel-
force-pushed
the
oak-nse/20-ambiguous-effects
branch
3 times, most recently
from
July 31, 2026 12:28
2efa13d to
630eec0
Compare
lionel-
force-pushed
the
oak-nse/20-ambiguous-effects
branch
from
July 31, 2026 14:23
630eec0 to
c1fd8b4
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Progress towards #1338
a
library()in anif/elsebranch no longer leaks its attach effect into the sibling branch during scan.A lazy body (function,
reactive()) defined inside a branch still sees that branch's attach at its own definition point, even though the attach doesn't survive past the branch's join.An attach or binding conditional in a branch/loop that might not run now logs an effect ambiguity diagnostic:
EffectAmbiguitydiagnostic (replacingLazyShadowAmbiguity/ConditionalShadowAmbiguity) flags three cases where an effect decision depends on a runtime condition: lazy-crossed shadowing, conditional local shadowing, and now conditional attaches too.These diagnostics are currently only logged but will be surfaced in a subsequent PR.
Positron Release Notes
New Features
Bug Fixes