notation: \ am Zeilenende setzt die Zeile fort (SPEC §1, D59)
Eine Zeile trägt alles auf einmal — im mitgelieferten Plan ist die längste 122 Zeichen lang, und seit das Textfeld nicht mehr umbricht (D49) muss man dafür schieben. Ein `\` am Zeilenende verteilt sie jetzt auf mehrere Textzeilen, ohne dass ein neuer Knoten entsteht. Leerraum davor ist Pflicht (`… \`, nicht `…\`) — bewusst gegen die Shell-Gewohnheit: Ohne die Regel verschluckt ein Label wie `C:\temp\` stumm den folgenden Knoten, mit ihr bekommt man nur keine Fortsetzung, was man sofort sieht. Der laute Fehler ist der bessere. Umgesetzt als Vor-Durchlauf `logicalLines()`: Die Folgezeile ist Teil der Zeile, bevor irgendetwas aus ihr gelesen wird — die Extraktionsreihenfolge aus §1 bleibt unangetastet. Alles gehört zur ersten Zeile: Einrückung, Warnungs-Zeilennummer, Rückschreiber; der Cursor in der Fortsetzung wählt ihren Knoten aus, wie bei Beschreibungszeilen. SPEC §1/§9, llms.md, Legende in neun Sprachen, D59; 20 neue Tests. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5
parent
257aab08dd
commit
410dacdc6c
@@ -18,6 +18,25 @@ https://werkbaum.javagil.de renders the notation as a diagram;
|
||||
|
||||
One node per line. Everything except the label is optional.
|
||||
|
||||
### Line continuation (`\` at the end)
|
||||
|
||||
- A line ending in **whitespace followed by `\`** continues on the next line:
|
||||
no new node begins. The `\` and the next line's indentation are dropped, the
|
||||
two parts are joined with **exactly one space**. Several `\` in a row extend
|
||||
the line further.
|
||||
- The whitespace before the `\` is **required** — `C:\temp\` stays a label and
|
||||
does not swallow the following node. Note this differs from shell habit,
|
||||
where `foo\` continues.
|
||||
- Everything belongs to the **first** line: its indentation sets the level, its
|
||||
number is the one warnings report, and tools that write back (fold mark, id
|
||||
shorthand) only touch it.
|
||||
- A token must not be split across the break — the join inserts a space, so a
|
||||
cut URL stays cut.
|
||||
- Only in the tree part. Behind the `---` divider line breaks are paragraph
|
||||
structure, and `\` is ordinary text.
|
||||
- Comments are removed **first**: `- A \ %% note` continues, `- A %% note \`
|
||||
does not.
|
||||
|
||||
### Hierarchy (indentation)
|
||||
|
||||
- Indentation defines the tree: a node's parent is the nearest line **above**
|
||||
|
||||
Reference in New Issue
Block a user