CodeMaid inserts excplicit private access modifier for partial methods
Environment
- Visual Studio version: 2022 Community 17.2.4
- CodeMaid version: 12.0
- Code language: C#
Description
CodeMaid inserts excplicit "private" access modifier for partial methods.
namespace ExampleNamespace
{
public partial class ExampleClass
{
partial void ExampleMethod();
}
}
Current behavior
Private access modifier is added to method which is not valid C# code and won't compile.
namespace ExampleNamespace
{
public partial class ExampleClass
{
private partial void ExampleMethod();
}
}
Expected behavior
namespace ExampleNamespace
{
public partial class ExampleClass
{
partial void ExampleMethod();
}
}
Thank you for reporting the issue. I believe this is related to an underlying SDK issue introduced in VS2022. There are some more details in #879 and a link over to the Roslyn SDK issue. The recommended workaround at this time is to disable the CodeMaid options that insert explicit access modifiers.
Is it possible to temporarily add an option to disable adding modifiers for partial methods? Turning it off completely simply because of partials, feels like a waste imho