JetBrains Rider 2024.3 Help

Members Generation

This page of JetBrains Rider options allows you to adjust code generation settings. For more information, refer to Code generation.

Generated member default body style

This setting allows you to choose what will be added in the bodies of generated members.

  • Throw new NotImplementedException(): When this option is selected, JetBrains Rider throws NotImplementedException() in bodies of generated members.

  • Return default value: When this option is selected, JetBrains Rider creates default value return statement in generated members, according to the return type.

  • Uncompilable code: When this option is selected, JetBrains Rider fills bodies in generated members with symbols that prevent compilation, forcing you to provide a meaningful implementation.

Generated property style

This setting defines how properties are generated for implementing and overriding members

  • Automatic property

  • Property with backing field

  • Accessors with default body: The default body is generated depending on the Generated member default body style setting described above.

Generated documentation

This setting defines how XML comments are generated for implementing and overriding members:

  • None: no XML comments will be added to generated members.

  • Add <inheritdoc/> for overridden members: this tag is a good alternative to copying documentation from base members. Although the tag is non-standard, it is understood by tools such as NDoc, Sandcastle, and Stylecop.

  • Copy XML documentation from overridden members this option allows copying XML doc comments from the overridden members to the generated overriding/implementing members.

Other options

Place backing field above property

When JetBrains Rider generates property for a field, a new property with a backing field, or transforms an auto-property to a property with a backing field, the field will be always placed above the property.

Wrap generated members in regions

Groups overriding and implemented members within regions with names describing the generated content, for example Overrides of [name of base class] and Implementation of [name of base interface].

Annotate property accessors with [DebuggerStepThrough]

When selected, adds the DebuggerStepThrough attribute to getters and setters of generated properties to prevent debugger from stepping into the property accessors.

Last modified: 11 February 2024