Skip to content

Commit

Permalink
docs: fix string literal example formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
rhendric committed Jul 31, 2024
1 parent 9e8afc6 commit 17318bc
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions doc/manual/src/language/string-literals.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ The following must be escaped to represent them within a string, by prefixing wi
> "\""
> ```
>
> "\""
> "\""
- Backslash (`\`)
Expand All @@ -46,7 +46,7 @@ The following must be escaped to represent them within a string, by prefixing wi
> "\\"
> ```
>
> "\\"
> "\\"
- Dollar sign followed by an opening curly bracket (`${`) – "dollar-curly"
Expand All @@ -56,7 +56,7 @@ The following must be escaped to represent them within a string, by prefixing wi
> "\${"
> ```
>
> "\${"
> "\${"
The newline, carriage return, and tab characters can be written as `\n`, `\r` and `\t`, respectively.
Expand All @@ -68,7 +68,7 @@ A "double-dollar-curly" (`$${`) can be written literally.
> "$${"
> ```
>
> "$\${"
> "$\${"
String values are output on the terminal with Nix-specific escaping.
Strings written to files will contain the characters encoded by the escaping.
Expand Down Expand Up @@ -107,10 +107,11 @@ each line, so the resulting string is
> >
> > The following indented string is prefixed with tabs:
> >
> > ''
> > <pre><code class="nohighlight">''
> > all:
> > @echo hello
> > ''
> > </code></pre>
> >
> > "\tall:\n\t\t@echo hello\n"
Expand Down

0 comments on commit 17318bc

Please sign in to comment.