Ah, thanks. Looks like I was using the singular in my source already.
Here’s the output:
run
└─ run exe jellytune
└─ compile exe jellytune Debug native 1 errors
src/main.zig:9:39: error: root source file struct 'builtin' has no member named 'mode'
break :gpa switch (std.builtin.mode) {
~~~~~~~~~~~^~~~~
/home/gwendolyn/dev/Remote-Repos/github.com/ziglang/zig/build-0.15.1/stage3/lib/zig/std/builtin.zig:1:1: note: struct declared here
//! Types and values provided by the Zig language.
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@import("builtin") is a zig file that the compiler generates for each compilation, it provides a lot of meta data for the specific compilation.
std.builtin is file in the standard library, it contains mostly type definitions that are used by the compiler, such as Type used for type reflection and generation, StackTrace, AtomicOrder, OptimizeMode, etc.
Think of it as something that is builtin into the compiler similar to how you can use @import("std") everywhere (without manually declaring a module for it), you can use --show-builtin to see what is within @import("builtin"):
I will say that I don’t believe it’s absolutely necessary that “builtin” mean three different things in Zig. It might be clearer if the one with build info were pronounced @import("buildinfo"), for example.