# result location semantics for \`@bitCast\` · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/17b1ac5d03cd32e047d917a88e029c143cb5d119)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: 17b1ac5d03cd32e047d917a88e029c143cb5d119

Requested commit: 17b1ac5d03cd32e047d917a88e029c143cb5d119

Commit: 17b1ac5d03cd32e047d917a88e029c143cb5d119

Tree: 0bdd3b27eaeaccbc17946a79cca6e8b628bb1d38

Author: Andrew Kelley

Committer: Andrew Kelley

## Message

````
result location semantics for `@bitCast`

```zig
export fn entry() void {
    var x = @bitCast(f32, foo());
}
```

```llvm
define void @entry() #2 !dbg !35 {
Entry:
  %x = alloca float, align 4
  %0 = bitcast float* %x to %Foo*, !dbg !42
  call fastcc void @foo(%Foo* sret %0), !dbg !42
  call void @llvm.dbg.declare(metadata float* %x, metadata !39, metadata !DIExpression()), !dbg !43
  ret void, !dbg !44
}
```

````

## Parents

- [1a51bf63047e9a3cd6ae3273296fded82009235c](https://git.cafe/gitcafe/zig/commit/1a51bf63047e9a3cd6ae3273296fded82009235c?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/17b1ac5d03cd32e047d917a88e029c143cb5d119?format=markdown)
