Skip to content

[Bug Report] TMIN / -1 should raise SIGFPE #63

@svaderia

Description

@svaderia

Describe the bug
TMIN / -1 should raise SIGFPE since the result would overflow.

To Reproduce

#use <conio>

int main() {
    int x = -2147483648;  // TMIN
    printint(x / -1);
    return (x / -1);
}

Expected behavior
SIGFPE

The standard cc0 compiler would raise SIGFPE. (might be a bug with constant propagation?)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions