Skip to content

Document numeric conversions #14031

@ArchRobison

Description

@ArchRobison

It seems that the Julia documentation does not cover numeric conversions. I think the subject deserves mention as a section of Mathematical Operations and Elementary Functions, with cross references between it and the Conversion and Promotion chapter.

How many forms should it cover? The three forms I find myself using are:

  • Int(x) - checked for exactness, i.e. value preserving
  • x % Int - modular, restricted to integer types
  • floor( Int, x ) - checked for exactness after flooring (and is documented)

I would describe the three forms and their tradeoffs. Any others worth documenting in said section of the manual?

Metadata

Metadata

Assignees

No one assigned

    Labels

    docsThis change adds or pertains to documentation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions