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

Unable to parse argument destructuring syntax #379

Open
MasonProtter opened this issue Nov 16, 2024 · 0 comments
Open

Unable to parse argument destructuring syntax #379

MasonProtter opened this issue Nov 16, 2024 · 0 comments

Comments

@MasonProtter
Copy link
Contributor

Looks like the internal parsing doesn't understand destructuring syntax:

julia> @macroexpand @btime (;a, b) = c
ERROR: MethodError: Cannot `convert` an object of type Expr to an object of type Symbol
The function `convert` exists, but no method is defined for this combination of argument types.

Closest candidates are:
  Symbol(::Any...)
   @ Base strings/basic.jl:229
  convert(::Type{T}, ::T) where T
   @ Base Base.jl:126

Stacktrace:
 [1] push!(a::Vector{Symbol}, item::Expr)
   @ Base ./array.jl:1249
 [2] _append!(a::Vector{Symbol}, ::Base.HasShape{1}, iter::Vector{Any})
   @ Base ./array.jl:1327
 [3] append!
   @ ./array.jl:1318 [inlined]
 [4] collectvars(ex::Expr, vars::Vector{Symbol})
   @ BenchmarkTools ~/.julia/packages/BenchmarkTools/QNsku/src/execution.jl:349
 [5] collectvars(ex::Expr)
   @ BenchmarkTools ~/.julia/packages/BenchmarkTools/QNsku/src/execution.jl:344
 [6] var"@benchmarkable"(__source__::LineNumberNode, __module__::Module, args::Vararg{Any})
   @ BenchmarkTools ~/.julia/packages/BenchmarkTools/QNsku/src/execution.jl:491
 [7] #macroexpand#74
   @ ./expr.jl:125 [inlined]
 [8] top-level scope
   @ REPL[4]:1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant