Closed
Description
pub fn f(_: &(ToString + 'static)) {}
This function is documented as:
The parentheses are missing and the function would not compile without them:
error[E0178]: expected a path on the left-hand side of `+`, not `&ToString`
--> src/main.rs:1:13
|
1 | pub fn f(_: &ToString + 'static) {}
| ^^^^^^^^^^^^^^^^^^^ help: try adding parentheses: `&(ToString + 'static)`
Metadata
Metadata
Assignees
Labels
No labels