Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Commit 16326cf

Browse files
jkotassafern
authored andcommitted
Fix modf and fmod casing for consistency
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com> Signed-off-by: dotnet-bot-corefx-mirror <dotnet-bot@microsoft.com>
1 parent 199f718 commit 16326cf

File tree

1 file changed

+3
-3
lines changed
  • src/Common/src/CoreLib/System

1 file changed

+3
-3
lines changed

src/Common/src/CoreLib/System/Math.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -624,7 +624,7 @@ public static double Round(double a)
624624

625625
double flrTempVal = Floor(a + 0.5);
626626

627-
if ((a == (Floor(a) + 0.5)) && (fmod(flrTempVal, 2.0) != 0))
627+
if ((a == (Floor(a) + 0.5)) && (FMod(flrTempVal, 2.0) != 0))
628628
{
629629
flrTempVal -= 1.0;
630630
}
@@ -664,7 +664,7 @@ public static unsafe double Round(double value, int digits, MidpointRounding mod
664664

665665
if (mode == MidpointRounding.AwayFromZero)
666666
{
667-
var fraction = modf(value, &value);
667+
var fraction = ModF(value, &value);
668668

669669
if (Abs(fraction) >= 0.5)
670670
{
@@ -755,7 +755,7 @@ public static decimal Truncate(decimal d)
755755

756756
public static unsafe double Truncate(double d)
757757
{
758-
modf(d, &d);
758+
ModF(d, &d);
759759
return d;
760760
}
761761

0 commit comments

Comments
 (0)