c0e9b57371
The change updates the logic to determine if a function parameter is valid for replacing the type param with the trait implementation. First all usages are determined, to check if they are used outside the function parameter list. If an outside reference is found, e.g. in body, return type or where clause, the assist is skipped. All remaining usages only appear in the function param list. For each usage the param type is checked to see if it's valid. **Please note** the logic currently follows a heuristic and may not cover all existing parameter declarations. * determine valid usage references by checking ancestors (on AST level) * split test into separate ones |
||
---|---|---|
.. | ||
src | ||
Cargo.toml |