Skip to content

Commit 7ec46f0

Browse files
authored
Merge pull request #32848 from compnerd/divide-and-conquer
validation: explicitly use integral division
2 parents b327dbf + 8d5c010 commit 7ec46f0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

validation-test/stdlib/FixedPoint.swift.gyb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ var FixedPoint = TestSuite("FixedPoint")
88

99
%{
1010

11+
from __future__ import division
1112
import gyb
1213
from SwiftIntTypes import all_integer_types
1314

@@ -248,7 +249,7 @@ FixedPoint.test("${Self}.hash(into:)") {
248249
% if self_ty.bits == 64:
249250
let expected = Hasher._hash(seed: 0, ${reference} as UInt64)
250251
% else:
251-
let expected = Hasher._hash(seed: 0, bytes: ${reference}, count: ${self_ty.bits / 8})
252+
let expected = Hasher._hash(seed: 0, bytes: ${reference}, count: ${self_ty.bits // 8})
252253
% end
253254
expectEqual(expected, output, "input: \(input)")
254255
}

0 commit comments

Comments
 (0)