Skip to content

Commit

Permalink
@rule gives error if more than one option (besides ) is passed.
Browse files Browse the repository at this point in the history
  • Loading branch information
zengmao committed Aug 29, 2024
1 parent 0a380ed commit 646dd70
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/rule.jl
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ macro rule(expr, option...)
@assert expr.head == :call && expr.args[1] == :(=>)
fullac = false
if length(option) > 0
@assert option[1] == :fullac "@rule only accepts one option `fullac` after the rule itself"
@assert length(option) == 1 && option[1] == :fullac "@rule only accepts one option `fullac` after the rule itself"
fullac = true
end
lhs = expr.args[2]
Expand Down

0 comments on commit 646dd70

Please sign in to comment.