Skip to content

Commit

Permalink
Allow macrocall in function def syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
Keno committed Jul 8, 2024
1 parent ae7d6ac commit ad110b9
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/parser.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2102,6 +2102,10 @@ function parse_function_signature(ps::ParseState, is_function::Bool)
if peek(ps) != K"("
# function f() end ==> (function (call f))
parse_unary_prefix(ps)
if peek_behind(ps).kind == K"macrocall"
min_supported_version(v"1.12", ps, mark, "macrocall function sig")
needs_parse_call = false
end
else
# When an initial parenthesis is present, we need to distinguish
# between
Expand Down

0 comments on commit ad110b9

Please sign in to comment.