From 93e990b36b4bf27e58ebf69c70a500cf7ccde8e2 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 5 Jan 2026 16:28:19 +0000 Subject: [PATCH 1/2] Initial plan From 9ee9db9430b4a5681e4c8bd2b7a478b7cb0ea6be Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 5 Jan 2026 16:32:40 +0000 Subject: [PATCH 2/2] Rewrite primary constructor rationale in active voice Converted passive voice paragraph to active voice with conversational tone per style guidelines. Uses "you" form and simpler, more direct language. Co-authored-by: gewarren <24882762+gewarren@users.noreply.github.com> --- docs/fundamentals/code-analysis/style-rules/ide0290.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/fundamentals/code-analysis/style-rules/ide0290.md b/docs/fundamentals/code-analysis/style-rules/ide0290.md index 9da9851ff7ec8..ffde613497f3e 100644 --- a/docs/fundamentals/code-analysis/style-rules/ide0290.md +++ b/docs/fundamentals/code-analysis/style-rules/ide0290.md @@ -24,7 +24,7 @@ dev_langs: This rule flags classes that can use a [primary constructor](../../../csharp/programming-guide/classes-and-structs/instance-constructors.md#primary-constructors) instead of a separate constructor definition. You define a primary constructor by placing any constructor parameters in parentheses following the type name. A primary constructor indicates that these parameters are necessary for any instance of the type. -The ability of a class or struct in C# to have more than one constructor provides for generality, but at the expense of some tedium in the declaration syntax, because the constructor input and the class state need to be cleanly separated. Primary constructors put the parameters of one constructor in scope for the whole class or struct to be used for initialization or directly as object state. The trade-off is that any other constructors must call through the primary constructor. +When you create a class or struct with multiple constructors, you gain flexibility, but you also add verbose syntax. You must cleanly separate the constructor input from the class state. With primary constructors, you can put one constructor's parameters in scope for the whole class or struct. You can use these parameters for initialization or directly as object state. However, if you add other constructors, they must call through the primary constructor. ## Options