Skip to content

Documented output type for yearmonthday #45

@haakon-e

Description

@haakon-e

The documented output type for yearmonthday is:

"""
    yearmonthday(dt::AbstractCFDateTime) -> (Int64, Int64, Int64)

Simultaneously return the year, month and day parts of `dt`.
"""

However, this is not always correct. Consider the following example:

julia> t2 = DateTimeStandard(Int128,2001,1,1)
DateTimeStandard(2001-01-01T00:00:00)


julia> yearmonthday(t2)
(2001, 1, 1)

julia> yearmonthday(t2) |> typeof
Tuple{Int128, Int128, Int128}

this also applies to related functions.


ref: openjournals/joss-reviews#8487

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions