From 1a08c0d40b8c6e72532762281365a5105116dc00 Mon Sep 17 00:00:00 2001 From: Andrew Kelley Date: Thu, 23 Jan 2020 00:46:44 -0500 Subject: [PATCH] new test case --- test/stage1/behavior/bitcast.zig | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/test/stage1/behavior/bitcast.zig b/test/stage1/behavior/bitcast.zig index fe3dd6902d..9c315c169c 100644 --- a/test/stage1/behavior/bitcast.zig +++ b/test/stage1/behavior/bitcast.zig @@ -167,3 +167,12 @@ test "nested bitcast" { S.foo(42); comptime S.foo(42); } + +test "bitcast passed as tuple element" { + const S = struct { + fn foo(args: var) void { + expect(args[0] == 1.00000e-09); + } + }; + S.foo(.{@bitCast(f32, @as(u32, 814313563))}); +}