Lossy conversion from Int64/UInt64 to Int32/UInt32
This commit is contained in:
parent
901e19c052
commit
018d21ee65
@ -11,7 +11,7 @@ extension Int: Identifiable {
|
||||
public var id: Int { self }
|
||||
/// The C integer.
|
||||
public var cInt: Int32 {
|
||||
.init(self)
|
||||
.init(truncatingIfNeeded: self)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -9,7 +9,7 @@ extension UInt {
|
||||
|
||||
/// Convert an unsigned integer into the C form.
|
||||
public var cInt: UInt32 {
|
||||
.init(self)
|
||||
.init(truncatingIfNeeded: self)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user