| 1 | const std = @import("std"); |
| 2 | const expectEqual = std.testing.expectEqual; |
| 3 | |
| 4 | test "coercing large integer type to smaller one when value is comptime-known to fit" { |
| 5 | const x: u64 = 255; |
| 6 | const y: u8 = x; |
| 7 | try expectEqual(255, y); |
| 8 | } |
| 9 | |
| 10 | // test |