Evenementer
Mar 17, 11 PM - Mar 21, 11 PM
Maacht mat bei der Meetup-Serie, fir skaléierbar KI-Léisungen op Basis vu realistesche Benotzungsfäll mat aneren Entwéckler an Experten ze bauen.
Elo umellenDëse Browser gëtt net méi ënnerstëtzt.
Upgrat op Microsoft Edge fir vun de Virdeeler vun leschten Eegeschaften, Sécherheetsupdaten, an techneschem Support ze profitéieren.
The following table lists the C# built-in value types:
The following table lists the C# built-in reference types:
C# type keyword | .NET type |
---|---|
object |
System.Object |
string |
System.String |
dynamic |
System.Object |
In the preceding tables, each C# type keyword from the left column (except dynamic) is an alias for the corresponding .NET type. They're interchangeable. For example, the following declarations declare variables of the same type:
int a = 123;
System.Int32 b = 123;
The void
keyword represents the absence of a type. You use it as the return type of a method that doesn't return a value.
The C# language includes specialized rules for the System.Span<T> and System.ReadOnlySpan<T> types. These types aren't classified as built-in types, because there aren't C# keywords that correspond to these types. The C# language defines implicit conversions from array types and the string type to Span<T>
and ReadOnlySpan<T>
. These conversions integrate Span
types into more natural programming scenarios. The following conversions are defined as implicit span conversions:
E
to System.Span<E>
E
to System.ReadOnlySpan<U>
, when E
has covariance conversion or an identity conversion to U
System.Span<E>
to System.ReadOnlySpan<U>
, when E
has a covariance conversion or an identity conversion to U
System.ReadOnlySpan<E>
to System.ReadOnlySpan<U>
, when E
has a covariance conversion or an identity conversion to U
string
to System.ReadOnlySpan<char>
The compiler never ignores any user defined conversion where an applicable implicit span conversion exists. Implicit span conversions can be applied to the first argument of extension methods, the parameter with the this
modifier. Implicit span conversions aren't considered for method group conversions.
Feedback zu .NET
.NET ass en Open-Source-Projet. Wielt e Link, fir Feedback ze ginn:
Evenementer
Mar 17, 11 PM - Mar 21, 11 PM
Maacht mat bei der Meetup-Serie, fir skaléierbar KI-Léisungen op Basis vu realistesche Benotzungsfäll mat aneren Entwéckler an Experten ze bauen.
Elo umellen