Skip to content

lcm should throw when one arg is infinite and the other is finite #56991

@LilithHafner

Description

@LilithHafner
julia> lcm(1//0, 3//2)
3//2 # Should throw

julia> lcm(1//0, 1//0)
1//0 # Correct

julia> lcm(0//1, 2//3)
0//1 # Correct

julia> lcm(1//0, -1//0)
1//0 # Correct

Originally posted by @LilithHafner as part of a comment from triage in #56423 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    mathsMathematical functionsminor changeMarginal behavior change acceptable for a minor releaserationalsThe Rational type and values thereof

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions