New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added static_face as variation of face #2520
Conversation
Something of note, the |
#[must_use]
fn rand() -> i32 {
4
}
fn main() {
rand(); // warning: unused return value of `rand` that must be used
} On structs, the effect of the attribute will apply anywhere the type is used (that is, in any function where it is used as return type). It is very useful if the whole point of calling a function is to perform further calculations on its return value, as the function does not have a side-effect (like writing to the filesystem); or if it does, there could be reasons why ignoring the return value might be bad (for instance, |
Ah, that's quite useful to know. Thanks for the information. |
This copies the
face()
function inuser.rs
, but usesstatic_avatar_url
instead ofavatar_url
.I am not sure if the
#[must_use]
is needed, since I don't exactly know what it does. If not, I will remove it in a follow up commit.