mirror of
https://github.com/ziglang/zig.git
synced 2024-11-15 16:45:27 +00:00
add test for previous commit
This commit is contained in:
parent
61c0c6d502
commit
2cce171448
@ -939,6 +939,15 @@ test "fmt.format" {
|
||||
try testFmt("struct: Struct{ .field = 42 }\n", "struct: {}\n", value);
|
||||
try testFmt("struct: Struct{ .field = 42 }\n", "struct: {}\n", &value);
|
||||
}
|
||||
{
|
||||
const Enum = enum {
|
||||
One,
|
||||
Two,
|
||||
};
|
||||
const value = Enum.Two;
|
||||
try testFmt("enum: Enum.Two\n", "enum: {}\n", value);
|
||||
try testFmt("enum: Enum.Two\n", "enum: {}\n", &value);
|
||||
}
|
||||
{
|
||||
var buf1: [32]u8 = undefined;
|
||||
const value: f32 = 1.34;
|
||||
|
Loading…
Reference in New Issue
Block a user