From f4bd723d929e53475f7990374dca7b7dfcbbdc42 Mon Sep 17 00:00:00 2001 From: Cliff Click Date: Sun, 1 Nov 2026 10:33:55 -0800 Subject: Add Chapter 29 for tech debt cleanup with the parser split Keep Chapter 28b intact and carry the grammar-oriented parser package, Var move, IterPeeps move, and parser regression tests into Chapter 29. Defer privacy and exclude its experimental tests and fixture changes. Register the chapter in the indexes, IntelliJ modules and run configurations, Maven reactor, roadmap, and linear-history publisher. Windows and Linux each pass 573 tests, release builds, 199 allocation replays, and 29 native checks. --- chapter29/README.ja.md | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 chapter29/README.ja.md (limited to 'chapter29/README.ja.md') diff --git a/chapter29/README.ja.md b/chapter29/README.ja.md new file mode 100644 index 00000000..f4bb10b6 --- /dev/null +++ b/chapter29/README.ja.md @@ -0,0 +1,27 @@ +# 第29章: 技術的負債の整理 + +[English](README.md) | 日本語 + +[前の章: 第28b章 — 分離コンパイル](../chapter28b/README.ja.md) + +この章では、第28b章の言語と分離コンパイルの動作を保ちながら、コンパイラを +読みやすく、変更しやすく整理します。最初の変更は、3,000行を超えたパーサを +文法のまとまりに沿って `parser/` パッケージへ分割することです。 + +`Parser` がカーソル、スコープ、型の登録情報を持ち、各部品は `Parser P` を +共有します。構文解析は引き続き Sea-of-Nodes IR を直接生成します。 +`Var` は `parser/` に、反復ピープホール最適化の `IterPeeps` は `codegen/` に移ります。 + +[パーサの構成(英語)](src/main/java/com/seaofnodes/simple/parser/README.md)と +[文法と実装の対応表(英語)](docs/29-grammar.md)からコードをたどれます。 +コンストラクタの初期化完了チェックの整理は今後の課題です。 +ソース上のプライバシー制約は今回は追加せず、[ロードマップ](../docs/roadmap.md)に残します。 + +リポジトリのルートからビルドとテストを実行します。 + +```sh +make lib tests release CHAPTERS=chapter29 CTAGS= +``` + +IntelliJ では `chapter29` モジュールと **chapter29 tests** 実行設定を使用します。 +ネイティブ実行を使うテストの前に、Make でランタイムと `sys` ライブラリをビルドしてください。 -- cgit v1.2.3