#E0147: invisible character in code
Code holds a character that shows nothing or looks like a plain space: a zero-width space or joiner (U+200B to U+200D), a byte order mark past the start of the file (U+FEFF), a variation selector with nothing to change, a filler (U+3164), or a space such as U+00A0 NO-BREAK SPACE. Two lines that look the same could then mean different things, so Nabi reads none of them as code or inside a name. Delete the character, or write a plain space; in a string write it as an escape, "\u{200B}".
Below, the name in the f-string has a zero-width space in the middle, often left behind by copying from a web page or a chat:
let count = 3;
println(f"{count}");
error[E0147]: identifier `count` holds the invisible character U+200B ZERO WIDTH SPACE: it reads as `count` but is another name --> main.nabi:2:12 | 2 | println(f"{count}"); | ^^^^^^ | = note: as written: `co\u{200B}unt` = help: write `count`
Delete the character; the quick fix in your editor does it:
let count = 3;
println(f"{count}");
3
Inside a string or a comment the same characters are a hidden_chars warning instead: write them as \u{..} escapes so readers see them. A ZWJ inside an emoji sequence and a ZWNJ in Persian or an Indic script are what they look like and are not reported.
Related: E0002 bidirectional control character in source, E0148 character that only looks like a token
Found a mistake? Edit this page on GitHub. Last updated