forked from JuliaLang/julia
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
InteractiveUtils: make default argtype of
code_llvm
etc. work with …
…functions with single method (JuliaLang#42496) `code_llvm` and `code_native` expects a single matching method, but the default value of `types=Tuple` argument doesn't match with any function signature and so we actually can't use that default value. With this PR, the default argument type will be computed by `default_tt`, which returns an appropriate signature if a function only has a single method, otherwise returns `Tuple` (which is the same default value as before). Now `code_llvm` and `code_native` by default work with functions that have a single method, e.g.: ```julia code_llvm() do # previously, we need to call `code_llvm(()) do ... end` sin(42) end ```
- Loading branch information
1 parent
09d57e3
commit 519e31e
Showing
4 changed files
with
55 additions
and
10 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
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