# make type_allowed_in_extern more robust · gitcafe/zig

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

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

Visibility: public

Requested revision: 53ae03ebe9e0aa56bca1c9219a47d124b0435258

Requested commit: 53ae03ebe9e0aa56bca1c9219a47d124b0435258

Commit: 53ae03ebe9e0aa56bca1c9219a47d124b0435258

Tree: 2f69fc4aeb6bdbc9567338b033337c4556f5c0c0

Author: Andrew Kelley

Committer: Andrew Kelley

## Message

```
make type_allowed_in_extern more robust

Previously if the type parameter was a pointer, it would assert that the
size of the type was resolved. It used to be that the size of pointers was
always resolved, however with lazy values, pointers gained the
possibility of not having their size resolved.

Now, type_allowed_in_extern triggers the resolution of whether a pointer
is zero bits, and returns a possible error if the resolution fails.

This fixes a compiler assertion when building the
[zootdeck project](https://github.com/donpdonp/zootdeck). I do not have
a test case reduction for the issue.

```

## Parents

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

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