We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
@compact
1 parent 6ec599e commit ea0691bCopy full SHA for ea0691b
src/compact.jl
@@ -83,7 +83,7 @@ macro compact(fex, kwexs...)
83
# check input
84
Meta.isexpr(fex, :(->)) || error("expects a do block")
85
isempty(kwexs) && error("expects keyword arguments")
86
- all(ex -> Meta.isexpr(ex, :kw), kwexs) || error("expects only keyword argumens")
+ all(ex -> Meta.isexpr(ex, (:kw,:(=))), kwexs) || error("expects only keyword argumens")
87
88
# check if user has named layer:
89
name = findfirst(ex -> ex.args[1] == :name, kwexs)
0 commit comments