Skip to content

Commit 240052b

Browse files
committed
link between attributes
Link between the C# attribute page and the .NET fundamentals article on experimental attributes in the runtime.
1 parent 089dc6e commit 240052b

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

docs/csharp/language-reference/attributes/general.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ The Windows Foundation Metadata libraries use the <xref:Windows.Foundation.Metad
7272
Beginning in C# 12, types, methods, and assemblies can be marked with the <xref:System.Diagnostics.CodeAnalysis.ExperimentalAttribute?displayProperty=nameWithType> to indicate an experimental feature. The compiler issues a warning if you access a method or type annotated with the <xref:System.Diagnostics.CodeAnalysis.ExperimentalAttribute>. All types declared in an assembly or module marked with the `Experimental` attribute are experimental. The compiler issues a warning if you access any of them. You can disable these warnings to pilot an experimental feature.
7373

7474
> [!WARNING]
75-
> Experimental features are subject to changes. The APIs can change, or they can be removed in future updates. Including experimental features is a way for library authors to get feedback on ideas and concepts for future development. Use extreme caution when using any feature marked as experimental.
75+
> Experimental features are subject to changes. The APIs can change, or they can be removed in future updates. Including experimental features is a way for library authors to get feedback on ideas and concepts for future development. Use extreme caution when using any feature marked as experimental. You can learn more about how APIs are marked as experimental in our article on [preview APIs](../../../fundamentals/runtime-libraries/preview-apis.md#experimentalattribute).
7676
7777
You can read more details about the `Experimental` attribute in the [feature specification](~/_csharplang/proposals/csharp-12.0/experimental-attribute.md).
7878

docs/fundamentals/runtime-libraries/preview-apis.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,11 +48,11 @@ As an example, in .NET 6 the *generic math* library was marked with <xref:System
4848

4949
.NET 8 added <xref:System.Diagnostics.CodeAnalysis.ExperimentalAttribute>, which doesn't require any runtime or language preview features and simply indicates that a given API isn't stable yet.
5050

51-
When building against an experimental API, the compiler produces an error. Each feature that's marked as experimental has its own separate diagnostic ID. To express consent to using an experimental API, you suppress the specific diagnostic. You can do that via any of the means for suppressing diagnostics, but the recommended way is to add the diagnostic to the project's `<NoWarn>` property.
51+
When building against an experimental API, the compiler produces an error. Each feature that's marked as experimental has its own separate diagnostic ID. To express consent to using an experimental API, you suppress the specific diagnostic. You can do that via any of the means for suppressing diagnostics, but the recommended way is to add the diagnostic to the project's `<NoWarn>` property. The C# compiler
5252

5353
Since each experimental feature has a separate ID, consenting to using one experimental feature doesn't consent to using another.
5454

55-
For more information, see [Experimental features][experimental-overview].
55+
For more information, see [Experimental features][experimental-overview] and the article in the C# guide on [general attributes](../../csharp/language-reference/attributes/general.md#experimental-attributes).
5656

5757
## Guidance for library developers
5858

0 commit comments

Comments
 (0)