From 84d0ab4d258191ba7fac6a2b1b9d796e1541f6f8 Mon Sep 17 00:00:00 2001 From: Stephane MICHELOUD Date: Wed, 27 Jan 2021 18:01:31 +0100 Subject: [PATCH] two fixes in Markdown files --- docs/docs/reference/other-new-features/indentation.md | 5 +++-- docs/docs/reference/syntax.md | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/docs/docs/reference/other-new-features/indentation.md b/docs/docs/reference/other-new-features/indentation.md index 17c8794bf62b..2fdf8787f262 100644 --- a/docs/docs/reference/other-new-features/indentation.md +++ b/docs/docs/reference/other-new-features/indentation.md @@ -1,6 +1,6 @@ --- layout: doc-page -title: Optional Braces +title: "Optional Braces" --- Scala 3 enforces some rules on indentation and allows some occurrences of braces `{...}` to be optional: @@ -9,7 +9,8 @@ Scala 3 enforces some rules on indentation and allows some occurrences of braces - Second, some occurrences of braces `{...}` are made optional. Generally, the rule is that adding a pair of optional braces will not change the meaning of a well-indented program. -These changescan can be turned off with the compiler flag `-noindent`. +These changes can be turned off with the compiler flag `-noindent`. + ### Indentation Rules The compiler enforces two rules for well-indented programs, flagging violations as warnings. diff --git a/docs/docs/reference/syntax.md b/docs/docs/reference/syntax.md index d271de2a8369..91a0018335f7 100644 --- a/docs/docs/reference/syntax.md +++ b/docs/docs/reference/syntax.md @@ -87,19 +87,19 @@ semi ::= ‘;’ | nl {nl} ## Optional Braces -The lexical analyzer also inserts `indent` and `outdent` tokens that represent regions of indented code [at certain points](../reference/other-new-features-indentation.html) +The lexical analyzer also inserts `indent` and `outdent` tokens that represent regions of indented code [at certain points](../other-new-features/indentation.md). In the context-free productions below we use the notation `<<< ts >>>` to indicate a token sequence `ts` that is either enclosed in a pair of braces `{ ts }` or that constitutes an indented region `indent ts outdent`. Analogously, the notation `:<<< ts >>>` indicates a token sequence `ts` that is either enclosed in a pair of braces `{ ts }` or that constitutes an indented region `indent ts outdent` that follows a `:` at the end of a line. - ``` <<< ts >>> ::= ‘{’ ts ‘}’ | indent ts outdent :<<< ts >>> ::= [nl] ‘{’ ts ‘}’ | `:` indent ts outdent +``` ## Keywords