-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
effects: complete edge effect overrides
While working on #44515, I found we missed to override edge effect with effects set by `Base.@assume_effects`. This commit adds edge effect override mechanism for `:consistent`/`:effect_free`/`:nothrow` settings in the same way as we did for `:terminates_globally` in #44106. Now we can do something like: ```julia const ___CONST_DICT___ = Dict{Any,Any}(:a => 1, :b => 2) Base.@assume_effects :consistent :effect_free :terminates_globally consteval(f, args...) = f(args...) @test fully_eliminated() do consteval(getindex, ___CONST_DICT___, :a) end ```
- Loading branch information
Showing
3 changed files
with
77 additions
and
16 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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