aboutsummaryrefslogtreecommitdiff
path: root/test/behavior/basic.zig
diff options
context:
space:
mode:
Diffstat (limited to 'test/behavior/basic.zig')
-rw-r--r--test/behavior/basic.zig7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/behavior/basic.zig b/test/behavior/basic.zig
index ac9e776c76..11ecf089c5 100644
--- a/test/behavior/basic.zig
+++ b/test/behavior/basic.zig
@@ -942,3 +942,10 @@ test "comptime int in switch in catch is casted to correct inferred type" {
};
_ = b;
}
+
+test "vector initialized with array init syntax has proper type" {
+ comptime {
+ const actual = -@Vector(4, i32){ 1, 2, 3, 4 };
+ try std.testing.expectEqual(@Vector(4, i32){ -1, -2, -3, -4 }, actual);
+ }
+}