KeywordDispatch.jl icon indicating copy to clipboard operation
KeywordDispatch.jl copied to clipboard

Documentation for each method

Open matbesancon opened this issue 7 years ago • 1 comments

It would be nice to have each method be documentable

using KeywordDispatch

"""
	Gamma base structure
"""
struct Gamma
	v1::Float64
	v2::Int
end

@kwdispatch Gamma()

"""
	Construction with just v1
"""
@kwmethod Gamma(;v1) = Gamma(v1,42)

help?> Gamma
search: Gamma

  Gamma base structure

The "Construction with just v1" docstring does not appear

matbesancon avatar Sep 20 '18 09:09 matbesancon

Good point. This will be non-trivial, at the very least because of https://github.com/JuliaLang/julia/issues/23991.

simonbyrne avatar Sep 20 '18 20:09 simonbyrne