Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

@code_warntype on OpaqueClosure throws. #54375

Closed
KristofferC opened this issue May 6, 2024 · 0 comments · Fixed by #54378
Closed

@code_warntype on OpaqueClosure throws. #54375

KristofferC opened this issue May 6, 2024 · 0 comments · Fixed by #54378
Labels
bug Indicates an unexpected problem or unintended behavior

Comments

@KristofferC
Copy link
Member

julia> g = Base.Experimental.@opaque Tuple{Float64} x -> 0.0
(::Float64)::Float64->◌

julia> @code_warntype g(1.0)
ERROR: type OpaqueClosure has no field nargs
Stacktrace:
 [1] getproperty
   @ ./Base.jl:49 [inlined]
 [2] code_warntype(io::Base.TTY, f::Any, tt::Any; world::UInt64, interp::Core.Compiler.NativeInterpreter, debuginfo::Symbol, optimize::Bool, kwargs::@Kwargs{})
   @ InteractiveUtils ~/.julia/juliaup/julia-nightly/share/julia/stdlib/v1.12/InteractiveUtils/src/codeview.jl:156
 [3] code_warntype(io::Base.TTY, f::Any, tt::Any)
   @ InteractiveUtils ~/.julia/juliaup/julia-nightly/share/julia/stdlib/v1.12/InteractiveUtils/src/codeview.jl:146
 [4] code_warntype(::Any, ::Vararg{Any}; kwargs...)
   @ InteractiveUtils ~/.julia/juliaup/julia-nightly/share/julia/stdlib/v1.12/InteractiveUtils/src/codeview.jl:173
 [5] top-level scope
   @ REPL[12]:1
@KristofferC KristofferC added the bug Indicates an unexpected problem or unintended behavior label May 6, 2024
aviatesk added a commit that referenced this issue May 8, 2024
Fixes #54375

---------

Co-authored-by: Shuhei Kadowaki <[email protected]>
xlxs4 pushed a commit to xlxs4/julia that referenced this issue May 9, 2024
lazarusA pushed a commit to lazarusA/julia that referenced this issue Jul 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Indicates an unexpected problem or unintended behavior
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant