Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
undo wrong suggestion
  • Loading branch information
mairaw authored Jun 10, 2020
commit d62cbef7d826e8597224a67613cdb83605640396
2 changes: 1 addition & 1 deletion xml/System/Double.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3930,7 +3930,7 @@ This member is an explicit interface member implementation. It can be used only

Ordinarily, if you pass the <xref:System.Double.TryParse%2A?displayProperty=nameWithType> method a string that is created by calling the <xref:System.Double.ToString%2A?displayProperty=nameWithType> method, the original <xref:System.Double> value is returned. However, because of a loss of precision, the values may not be equal. In addition, attempting to parse the string representation of either <xref:System.Double.MinValue?displayProperty=nameWithType> or <xref:System.Double.MaxValue?displayProperty=nameWithType> fails to round-trip. On .NET Framework and .NET Core 2.2 and previous versions, it throws an <xref:System.OverflowException>. On .NET Core 3.0 and later versions, it returns <xref:System.Double.NegativeInfinity?displayProperty=nameWithType> if you attempt to parse <xref:System.Double.MinValue?displayProperty=nameWithtype> or <xref:System.Double.PositiveInfinity?displayProperty=nameWithType> if you attempt to parse <xref:System.Double.MaxValue?displayProperty=nameWithtype>. The following example provides an illustration.

:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Double.TryParse/cs/tryparse2.cs" interactive="try-dotnet-method" id="Snippet3":::
:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Double.TryParse/cs/tryparse2.cs" interactive="try-dotnet" id="Snippet3":::
:::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Double.TryParse/vb/tryparse2.vb" id="Snippet3":::

On .NET Framework and .NET Core 2.2 and earlier versions, if `s` is out of range of the <xref:System.Double> data type, the <xref:System.Double.TryParse%28System.String%2CSystem.Double%40%29> method throws an <xref:System.OverflowException>.
Expand Down