Uploaded image for project: 'Commons Math'
  1. Commons Math
  2. MATH-476

FastMath code contains 'magic' numbers, e.g. (-)4503599627370496.0

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 2.2
    • 3.2
    • None
    • None

    Description

      The FastMath class contains quite a few 'magic' numbers, not all of which are explained/documented.

      For example, how is the number (-)4503599627370496.0 calculated?

      IMO, all magic numbers should be replaced by constants with a descriptive name and explanatory Javadoc.

      Attachments

        Activity

          People

            Unassigned Unassigned
            sebb Sebb
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: