Skip to content

Commit 52e9211

Browse files
authored
Update SKILL.md
1 parent 923e717 commit 52e9211

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

  • .github/skills/csharp-snippet-modernization

.github/skills/csharp-snippet-modernization/SKILL.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ Apply these changes when they preserve behavior and sample clarity:
3434
timeZoneTime.DateTime);
3535
```
3636
- Use raw string literals (or interpolated raw string literals) for paragraph-style output.
37-
- Use the `new` operator to construct objects. Omit the type name after `new` when the target type is evident.
37+
- Use `new` to construct objects. Omit the type name when the target type is evident.
3838
- Use collection expressions to initialize collections and arrays wherever possible.
3939
- Convert eligible value-producing `switch` statements to switch expressions.
4040
- Use auto-implemented properties instead of defining a separate field.
@@ -52,7 +52,7 @@ Apply these changes when they preserve behavior and sample clarity:
5252
- Add `using` statements for disposable types, and remove redundant calls to `Close()` or `Dispose()`.
5353
- Prune unnecessary package references from project files.
5454
- Use compound assignment.
55-
- Replace calls to obsolete APIs with their replacement. For example, replace `WebRequest` with `HttpClient`.
55+
- Replace calls to obsolete APIs with their recommended replacements (per the `ObsoleteAttribute` message and official docs). For example, replace `WebRequest` with `HttpClient`.
5656

5757
Don't introduce `var`; this repository prefers explicit types.
5858

0 commit comments

Comments
 (0)