fn name_for_constructor_search(
syntax: &SyntaxNode,
position: FilePosition,
) -> Option<Name>Expand description
Returns Some if the cursor is at a position where we should search for constructor/initialization usages.
This is used to implement the special constructor search behavior when the cursor is on specific tokens
in a struct/enum/variant definition.
ยงReturns
Some(name)if the cursor is on:{after a struct/enum/variant definition(for tuple structs/variants;for unit structs- The type name in a struct/enum/variant definition
Noneotherwise
The returned name is the name of the type whose constructor usages should be searched for.