Rellum Rellum

S0031: unary minus requires Int or Float

Generated from rellum-diagnostics/src/db.rs.

Explanation

The unary - operator is numeric negation. It is defined only for Int and Float values; Rellum does not implicitly convert Bool, Char, String, arrays, records, or enums to numbers.

Common causes

Canonical fixes

Before:

value = -text

After:

value = -count

Code example

value = -text