Content-Length: 24176 | pFad | https://doc.rust-lang.org/std/string/../error/../string/../../std/../error_codes/./E0618.html

E0618 - Error codes index

Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Error code E0618

Attempted to call something which isn’t a function nor a method.

Erroneous code examples:

#![allow(unused)]
fn main() {
enum X {
    Entry,
}

X::Entry(); // error: expected function, tuple struct or tuple variant,
            // found `X::Entry`

// Or even simpler:
let x = 0i32;
x(); // error: expected function, tuple struct or tuple variant, found `i32`
}

Only functions and methods can be called using (). Example:

#![allow(unused)]
fn main() {
// We declare a function:
fn i_am_a_function() {}

// And we call it:
i_am_a_function();
}








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: https://doc.rust-lang.org/std/string/../error/../string/../../std/../error_codes/./E0618.html

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy