Bug 17501 - Math.Round (double.MaxValue, 1) results in Infinity
Summary: Math.Round (double.MaxValue, 1) results in Infinity
Status: NEW
Alias: None
Product: Runtime
Classification: Mono
Component: General (show other bugs)
Version: unspecified
Hardware: PC Linux
: --- normal
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2014-01-30 02:55 UTC by Atsushi Eno
Modified: 2014-01-30 02:55 UTC (History)
2 users (show)

See Also:
Tags:
Is this bug a regression?: ---
Last known good build:


Attachments

Description Atsushi Eno 2014-01-30 02:55:54 UTC
From http://d.hatena.ne.jp/hnw/20140129

double d = Double.MaxValue;
Console.WriteLine(d); // 1.79769313486232E+308
Console.WriteLine(Math.Round(d, 1)); // Infinity

.NET prints 1.79769313486232E+308 but I'm not sure if it is correct.

Note You need to log in before you can comment on or make changes to this bug.