Open and answer this issue on GitHub.
ready · opened 2026-10-31 · updated 2026-10-31 · 0 comments
Facts: Traps already met
An attribute struct without fields is not found where it is used: @Skip and f.attribute(Skip) are NK1135 “There’s no struct called Skip”. With one defaulted field the same program runs. Part II 10.3 (attributes) allows any struct @meta::Attribute marks; ADR-grammar-2 D4’s wire_name reads f.attribute(Skip), a marker attribute. Kind 3 (specified, does not work). Found by the tools architect, 2026-10-31.
target/fast/nikaia run, today’s binary)@meta::Attribute(field)
pub struct Skip {}
struct C {
@Skip
age: i64,
}
fn main() {
let c = C { age: 1 }
println(f"{c.age}")
}
Today: error[NK1135]: There's no struct called Skip at @Skip. Wanted: 1. pub struct Skip { pub on: bool = true } prints 1 today; a plain struct E {} with E {} works, so the loss is in the attribute path (where the marked structs are collected, likely skipping a struct whose field list is empty; not traced further).
@meta::Attribute structs are gathered for NK1135/NK1235, crates/nikaia-std/src/tools/check_*.nika; find with nikaia run scripts/where.nika -- NK1135.@Skip with pub struct Skip {} marked @meta::Attribute(field) resolves; f.attribute(Skip) in an unrolled turn is a Skip? that is not null on the marked field. Test tests/compiler/tests/a_fieldless_attribute.nika + .stdout (the probe, plus a show[T: Struct] that prints f.attribute(Skip) != null per field). Commit Fixes #N.Generated by Claude Code