Skip to content

Commit f210a7d

Browse files
authored
use kwargs accessors to get rid of warnings (#17)
1 parent 8f9aad4 commit f210a7d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/KeywordDispatch.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -172,8 +172,8 @@ macro kwdispatch(fexpr,methods=nothing)
172172

173173
quote
174174
$(wrap_where(:($(esc(f))($(esc.(posargs_method)...); kwargs...)), wherestack)) = begin
175-
N = map(kw -> $rename_expr, propertynames(kwargs.data))
176-
nt = NamedTuple{N}(Tuple(kwargs.data))
175+
N = map(kw -> $rename_expr, keys(kwargs))
176+
nt = NamedTuple{N}(Tuple(values(kwargs)))
177177
KeywordDispatch.kwcall(ntsort(nt), $ff, $(esc.(argsym.(posargs_method))...))
178178
end
179179
$(generate_kwmethods(methods, f, posargs, wherestack))

0 commit comments

Comments
 (0)