10000 Mention C# native integers in IntPtr/UIntPtr docs by MSDN-WhiteKnight · Pull Request #7364 · dotnet/dotnet-api-docs · GitHub
[go: up one dir, main page]

Skip to content

Mention C# native integers in IntPtr/UIntPtr docs #7364

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Nov 8, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
8000 Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions xml/System/IntPtr.xml
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,8 @@
The <xref:System.IntPtr> type is CLS-compliant, while the <xref:System.UIntPtr> type is not. Only the <xref:System.IntPtr> type is used in the common language runtime. The <xref:System.UIntPtr> type is provided mostly to maintain architectural symmetry with the <xref:System.IntPtr> type.

This type implements the <xref:System.Runtime.Serialization.ISerializable>, and, in .NET 5.0 and later, the <xref:System.IFormattable> interfaces.

In C# starting from version 9.0, you can use the built-in `nint` type to define native-sized integers. This type is represented by the <xref:System.IntPtr> type internally and provides operations and conversions that are appropriate for integer types. For more information, see [nint and nuint types](/dotnet/csharp/language-reference/builtin-types/nint-nuint).

## Examples

Expand Down
2 changes: 2 additions & 0 deletions xml/System/UIntPtr.xml
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,8 @@
The <xref:System.UIntPtr> type can be used by languages that support pointers, and as a common means of referring to data between languages that do and do not support pointers. <xref:System.UIntPtr> objects can also be used to hold handles.

This type implements the <xref:System.Runtime.Serialization.ISerializable>, and, in .NET 5.0 and later, the <xref:System.IFormattable> interfaces.

In C# starting from version 9.0, you can use the built-in `nuint` type to define native-sized integers. This type is represented by the <xref:System.UIntPtr> type internally and provides operations and conversions that are appropriate for integer types. For more information, see [nint and nuint types](/dotnet/csharp/language-reference/builtin-types/nint-nuint).

]]></format>
</remarks>
Expand Down
0