Skip to content

Commit c7f1df4

Browse files
Fix the value of Float80.pi (#12881)
Currently this is implemented as Float80(literal), which gets interpreted as Float80(Double(literal)), unfortunately. Switch to the correct spelling: literal as Float80. Resolves rdar://problem/35459284
1 parent 5015ee1 commit c7f1df4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

stdlib/public/core/FloatingPointTypes.swift.gyb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -559,11 +559,11 @@ extension ${Self}: BinaryFloatingPoint {
559559
// in angles in the wrong quadrant if users aren't careful. This is
560560
// not a problem for Double or Float80, as pi rounds down in both of
561561
// those formats.
562-
return Float(0x1.921fb4p1)
562+
return 0x1.921fb4p1
563563
%elif bits == 64:
564-
return Double(0x1.921fb54442d18p1)
564+
return 0x1.921fb54442d18p1
565565
%elif bits == 80:
566-
return Float80(0x1.921fb54442d1846ap1)
566+
return 0x1.921fb54442d1846ap1
567567
%end
568568
}
569569

0 commit comments

Comments
 (0)