E0018: must-use metadata on a verb without a result

View source

meta must_use("...") makes it an error to drop the result of a call.

meta must_use("...") makes it an error to drop the result of a call. ADR-0090 does not allow it on a declaration that returns nothing, because there would be no result to protect. The error points at the meta must_use line.

Example

actus
meta must_use("check the result")
verb main() {
}

Fix

Give the verb a return type, or remove the attribute.

actus
meta must_use("check the result")
verb parse_port() -> Int {
    return 80;
}

verb main() {
    erg port = parse_port();
}

Run actus explain E0018 in your terminal to read this entry offline. Browse Lexer & parser or all error codes.