Sisu
E0009

Integer literal too large for i64

Error

Built from the repository at commit a8614dc.

An integer literal must fit in an i64, which holds values up to 9223372036854775807.

Why

Sisu has no integer type that is wider than i64, so a literal beyond its range cannot hold the value it names. The one exception is -9223372036854775808, the smallest i64: a - directly before the literal makes one negative literal of them.

Broken

fn main() {
    let n = 9223372036854775808
    print(n)
}

What sisu says

error[E0009]: integer literal is too large for `i64`
 --> E0009.sisu:2:13
  |
2 |     let n = 9223372036854775808
  |             ^^^^^^^^^^^^^^^^^^^

sisu: 1 error
sisu: for more on a code, run `sisu explain <code>`: E0009

Fixed

fn main() {
    let n = 9223372036854775807
    print(n)
}