devchat-ai / devchat

Automate your dev tasks with AI-powered scripts, from your IDE's chat panel.
https://www.devchat.ai
Apache License 2.0
342 stars 39 forks source link

Incorrect Function Selection Range in Docstrings #291

Closed yangbobo2021 closed 6 months ago

yangbobo2021 commented 6 months ago

I have encountered an issue where the selection range for functions in docstrings does not include the last line. This results in a situation where, during code refactoring, the last line gets duplicated.

Expected Behavior The entire function, including the last line, should be selected. This is crucial for proper function extraction or other refactoring activities without causing line duplication.

Actual Behavior The selection excludes the last line of the function, leading to repeated lines after refactoring.