Skip to content

math/big: (*Float).Text and (*Float).Format don't support 'g' with negative precision #10991

@griesemer

Description

@griesemer

In analogy to the strconv.FormatFloat and fmt.Printf functions using the 'g' format, (_Float).Text and (_Float).Format should support the 'g' format with a negative precision (== smallest number of digits necessary to identify the floating-point value uniquely).

The implementation is in (*Float).Text.

Once fixed, the work-around (to avoid a panic) in (*Float).Format can be removed.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions