Home / Docs / Diagnostics
U0004: Unterminated text literal
Release v0.4.0
A text literal starts and ends with " on the same line; it cannot span lines (spec/01 §6). U0004 reports a literal whose closing quote is missing before the end of the line or of the file, including a literal whose interpolation is missing its }. Write a quote inside text as \" and a line break as \n.
The repair at a glance
diff
module demo
- pub greeting() -> Text = "hello
+ pub greeting() -> Text = "hello"Failing example
una
module demo
pub greeting() -> Text = "helloFixed example
una
module demo
pub greeting() -> Text = "hello"