# add implicit cast from enum to union · gitcafe/zig

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

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

Visibility: public

Requested revision: 960914a073c367883c9fdf54e900890a6aefc05f

Requested commit: 960914a073c367883c9fdf54e900890a6aefc05f

Commit: 960914a073c367883c9fdf54e900890a6aefc05f

Tree: 4dca5efa7967f0ecca20bd0d852005008a1ec925

Author: Andrew Kelley

Committer: Andrew Kelley

## Message

```
add implicit cast from enum to union

when the enum is the tag type of the union and is comptime known
to be of a void field of the union

See #642

```

## Parents

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

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