You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Therefore, smart pointer structs, such as Box, Arc
have many class function that is not method,
and the first parameter is the type itself
such as Box::into_raw, Arc::into_inner
Is it possible to add these functions to completion, when I press the period character after the object variable?
The functions can be limited to the function whose first parameter is Self, &Self, &mut Self
For example
let foo = Arc::new(1);
let bar = foo.
Is it possible to show Arc::into_inner in the completion list?
When the completion is accepted, the code is automatically rewritten to
let foo = Arc::new(1);
let bar = Arc::into_inner(foo);
The text was updated successfully, but these errors were encountered:
According to Rust API guidelines,
Smart pointers do not add inherent methods (C-SMART-PTR)
Therefore, smart pointer structs, such as
Box
,Arc
have many class function that is not method,
and the first parameter is the type itself
such as
Box::into_raw
,Arc::into_inner
Is it possible to add these functions to completion, when I press the period character after the object variable?
The functions can be limited to the function whose first parameter is
Self
,&Self
,&mut Self
For example
Is it possible to show
Arc::into_inner
in the completion list?When the completion is accepted, the code is automatically rewritten to
The text was updated successfully, but these errors were encountered: