I’m trying to build a library with the general frame something like:
pub struct Something {something}
impl Something {
fn x(){}
fn y() {
Something::x();
}
}
But this throws an error that Something has no method x.
Why is this the case? I had to make a copy of X method outside the impl just to be able to call it from inside the impl methods. Is there no way to get past this in a more elegant manner?