# compiler: replace \`@Type\` with individual type-creating builtins · gitcafe/zig

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

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

Visibility: public

Requested revision: c5383173a0de17210f3036acd942738e906997e5

Requested commit: c5383173a0de17210f3036acd942738e906997e5

Commit: c5383173a0de17210f3036acd942738e906997e5

Tree: 081ef03298de2fbfe679e7eb843f24036c7a9c1c

Author: Matthew Lugg

Committer: Matthew Lugg

## Message

```
compiler: replace `@Type` with individual type-creating builtins

The new builtins are:
* `@EnumLiteral`
* `@Int`
* `@Fn`
* `@Pointer`
* `@Tuple`
* `@Enum`
* `@Union`
* `@Struct`

Their usage is documented in the language reference.

There is no `@Array` because arrays can be created like this:

    if (sentinel) |s| [n:s]T else [n]T

There is also no `@Float`. Instead, `std.meta.Float` can serve this use
case if necessary.

There is no `@ErrorSet` and intentionally no way to achieve this.
Likewise, there is intentionally no way to reify tuples with comptime
fields, or function types with comptime parameters. These decisions
simplify the Zig language specification, and moreover make Zig code more
readable by discouraging overly complex metaprogramming.

Co-authored-by: Ali Cheraghi <alichraghi@proton.me>
Resolves: #10710

```

## Parents

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

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