The `eval` is going to do some really odd things there. If you're on a very
recent 0.5 build you should probably see the following output after doing
that
```
julia> for name in (:year, :month, :day, :hour, :minute, :second,
:millisecond)
func = eval(name)
@doc """
Thanks Mike, I also managed to come up with an alternative solution:
using Base.Dates
for name in (:year, :month, :day, :hour, :minute, :second, :millisecond)
func = eval(name)
@doc """
$name(dt::TimeType) -> Int64
Return the $name of a `Date` or `DateTime` as an `Int64`.
Just needs extra `$`s in the docstring, one for expression interpolation
and one for string interpolation:
julia> for name in (:year, :month, :day, :hour, :minute, :second, :
millisecond)
@eval begin
@doc """
$($name)(dt::TimeType) -> Int64