JetBrains Rider 2024.1 Help

Code Inspection: Redundant 'partial' modifier on type declaration

Category

Redundancies in Symbol Declarations

ID

PartialTypeWithSinglePart

EditorConfig

resharper_partial_type_with_single_part_highlighting

Default severity

Warning

Language

C#

Requires SWA

No

JetBrains Rider detects types declared as partial but consisting of only one part. If no other parts of the class are found in any file within the project, JetBrains Rider suggests removing the partial modifier from the class declaration.

Alternatively, you can create more parts of the class by invoking the Extract Members to Partial refactoring on the class name. The refactoring will help you create a new part of the class and move selected members there.

Last modified: 10 April 2024