You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Point unknown local annotation types at the type instead of the variable name #980
Unknown local annotation types are diagnosed at the variable identifier because validation marks the declaration name before checking the type. This is misleading for long or nested annotations and inconsistent with the parser's type-token diagnostics.
Reproduction
Audited canonical master 42b65e426ad45bf896623b5bce814312b694a0c7 on Linux amd64 with Rust 1.89 and LLVM 21.1.8. Reproductions use the checkout-built target/debug/wavec and matching checkout std. The local head d2f58962 has an identical file tree to that canonical merge. Commands below assume WAVEC names that binary.
fun main() {
var x: Undefined;
}
"$WAVEC" --error-format=json check main.wave
Observed: unknown type Undefined in variable x highlights only x, not Undefined. Also reproduced after leading blank lines: JSON line is correct but the span remains the declaration name. The failure is in semantic validation, not parsing.
Scope
Retain and use the physical type annotation range for unknown/invalid annotation diagnostics, including nested pointer/array/generic forms. Keep declaration-name focus for duplicate bindings and expression focus for initializer errors. Do not add type inference or change valid types.
Activity
Improve source diagnostics and reject recursive inline storage (wavef…