File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -294,7 +294,7 @@ extension Int128 {
294
294
public func dividedReportingOverflow(
295
295
by other: Self
296
296
) -> ( partialValue: Self , overflow: Bool ) {
297
- precondition ( other != . zero, " Division by zero " )
297
+ _precondition ( other != . zero, " Division by zero " )
298
298
if self == . min && other == - 1 { return ( . min, true ) }
299
299
return ( Self ( Builtin . sdiv_Int128 ( self . _value, other. _value) ) , false )
300
300
}
@@ -304,7 +304,7 @@ extension Int128 {
304
304
public func remainderReportingOverflow(
305
305
dividingBy other: Self
306
306
) -> ( partialValue: Self , overflow: Bool ) {
307
- precondition ( other != . zero, " Remainder dividing by zero. " )
307
+ _precondition ( other != . zero, " Division by zero in remainer operation " )
308
308
if self == . min && other == - 1 { return ( 0 , true ) }
309
309
return ( Self ( Builtin . srem_Int128 ( self . _value, other. _value) ) , false )
310
310
}
Original file line number Diff line number Diff line change @@ -505,7 +505,7 @@ extension UInt128.Words: RandomAccessCollection {
505
505
public subscript( position: Int ) -> UInt {
506
506
@inlinable
507
507
get {
508
- precondition ( position >= 0 && position < count)
508
+ _precondition ( position >= 0 && position < count, " Index out of bounds " )
509
509
var value = _value
510
510
#if _endian(little)
511
511
let index = position
You can’t perform that action at this time.
0 commit comments