Hello, everyone. While I was adding some docstrings to a mutable struct, I’ve realized that when the field is set as constant, the documentation doesn’t work. Take, for example, the following mutable struct:
"Some random docs I write here."
mutable struct Foo{T<:AbstractFloat}
"Mass"
const m::T
"Time"
t::T
end
If I enter into help mode and type Foo, I get the corresponding docstring:
help?> Foo
search: Foo Bool
Some random docs I write here.
The same happens with the field t:
help?> Foo.t
Time
However, when I search for the constant field, nothing shows up. As if that field didn’t have docstrings:
Foo.m
Foo has fields m, and t.
Is this a bug? I’ve read the corresponding section at the docs but nothing is mentioned. Writing @doc in front of the string does not work either.