Open Scrivener07 opened 5 years ago
I broke "Additional Prompts" off into its own issue #75.
Is this a feature plan to add this good feature or it's a feature announcement?? I mean Is that already available in your extension or it's a feature plan??
Is this a feature plan to add this good feature or it's a feature announcement?? I mean Is that already available in your extension or it's a feature plan??
The "Rename Symbol" feature is available in the current versions. It only has a problem in the particular context I detailed above.
Describe the bug Refactoring of scripts with "Rename Symbol" does not work as intended with script names. The symbol usage is renamed across files but but the script name identifier must match the script file name.
If I recall correctly, in Visual Studio with CSharp, the "Rename Symbol" also behaves this way, leaving the
*.cs
file name unchanged.However, in Visual Studio if you rename the
*.cs
within the project explorer, it will rename the file and prompt if you would also like to run "Rename Symbol" on the class name. What do you think about matching this behavior both ways in the extension?In CSharp it does not matter is the class name matches the file name but in Papyrus this will cause a compiler error. It does not seem well to leave code in a broken state resulting from a refactoring command.
Rename in VS Code Explorer
"Rename Symbol"
Additional Prompts
This applies to refactoring in general. Refactoring a symbol which reaches beyond the current file may do well with some additional checks.
For example is a user tries to rename an inherited function or event originating from a
Base
import or other library such asF4SE
.In cases where a refactored symbol's usage originates outside of the current user source folder, then prompt the user with.
The symbol "X" belongs to the import "Y". Are you Sure?
Or something like that to think about.