forked from JuliaLang/julia
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow PartialStruct on inference edges (JuliaLang#36521)
* Allow PartialStruct on inference edges At the moment, we only allow types, or completely Const inference results to propagate along inference edges. In particular PartialStruct is disallowed. I noticed some inference sub-optimalities as a result (e.g. in iterating `Pair`), but more generally, I would prefer if adding an additional return value somewhere (i.e. returning a tuple of two values, rather than a single value) would not degrade the inference precision for the previously returned value. This fixes the issue by allowing `PartialStruct` to propagate along inference edges. * Make sure to widenconst in return_type_tfunc
- Loading branch information
Showing
3 changed files
with
29 additions
and
13 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