Skip to content

Division by zero results in 'Infinity' or 'NaN' value #41

Open
@mkarup

Description

@mkarup

I'm not sure whether this is the intended semantics (side effect of using javascript?), but dividing a non-zero number by zero results in (+/-) Infinity

1/0

gives

>>> Main thread finished with value: Infinity@{}%{}

Similarly, dividing zero by zero results in a NaN value:

0/0

gives

>>> Main thread finished with value: NaN@{}%{}

The Infinity / NaN are also propagated when they are used in arithmetic operations with other values.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingcompilerCompiler-related issue

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions