Vec[(i64, String)] local, then moved into a struct field, reaches rustc (E0308)Open and answer this issue on GitHub.
ready · opened 2026-10-29 · updated 2026-10-29 · 0 comments
Building #948 (a builder’s side finding), re-checked on develop at 0.0.1279 (2f73c24), after #929 step 4 taught the text tiers to follow tuples.
struct LoopFound { parts: Vec[(i64, String)] }
fn text_of(found: LoopFound) -> String {
let mut out: String = ""
for (n, s) in found.parts {
out.push_str(f"{n} {s};")
}
return out
}
fn main() {
let guesses = [1, 2]
let mut parts: Vec[(i64, String)] = []
for guess in guesses {
parts.push((guess, "guess and check"))
}
println(text_of(LoopFound { parts: parts }))
}
nikaia check accepts it; nikaia run stops in rustc:
error: Mismatched types.
15 | parts.push((guess, "guess and check"))
= note: Consider dereferencing the borrow.
The same shape occurs in tools/bounds_walk.nika (around line 2293), where the #929 builder met it as NK1106. Related: #909 (a lent loop element moved into a tuple literal, also E0308).
tests/compiler/.The commit that builds the last step says Fixes #N.