Skip to content

Clarification of description of TimeSpan FromDays(double) #12327

@RobertOwenJack

Description

@RobertOwenJack

Type of issue

Typo

Description

The documentation states that the TimeSpan FromDays(double) function is accurate to a ms. This may well be so, but since .NET Core 3.1 the precision is no longer to 1 ms. I found this when comparing behavior in .NET Framework 4.8 and .NET 8 code and found the documentation confusing on this point. The former gave a precision to 1ms the later gave much higher precision. See https://stackoverflow.com/questions/60987108/why-are-the-timespan-values-different-between-netcoreapp2-1-and-netcoreapp3-1/61200495#61200495 and dotnet/runtime#13230
[Enter feedback here]

Page URL

https://learn.microsoft.com/en-us/dotnet/api/system.timespan.fromdays?view=net-10.0

Content source URL

https://github.com/dotnet/dotnet-api-docs/blob/main/xml/System/TimeSpan.xml

Document Version Independent Id

9bbc6835-9e06-d583-a77a-1ab32a2e5082

Platform Id

034e77eb-4b00-3d20-8af9-f364624e7ab9

Article author

@dotnet-bot

Metadata

Metadata

Assignees

No one assigned

    Labels

    needs-area-labelAn area label is needed to ensure this gets routed to the appropriate area ownersuntriagedNew issue has not been triaged by the area owner

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions