phase: 20.49 COMPLETE; 20.50 Flow+String minimal reps; 20.51 selfhost v0/v1 minimal (Option A/B); hv1-inline binop/unop/copy; docs + run_all + CURRENT_TASK -> 21.0

This commit is contained in:
nyash-codex
2025-11-06 15:41:52 +09:00
parent 2dc370223d
commit 77d4fd72b3
1658 changed files with 6288 additions and 2612 deletions

View File

@ -0,0 +1,63 @@
// フィールドアクセステスト
box Parent {
init { value }
constructor() {
me.value = "Parent Value"
}
getValue() {
return me.value
}
// 直接フィールド値をデバッグ
debugValue() {
return me.value
}
}
box Child : Parent {
init { childValue }
constructor() {
from Parent.constructor()
me.childValue = "Child Value"
}
test() {
// 親の値を直接取得
local parentValue
parentValue = from Parent.getValue()
// 親の値をデバッグ用メソッドで取得
local debugValue
debugValue = from Parent.debugValue()
return "Parent: " + parentValue + ", Debug: " + debugValue
}
}
static box Main {
init { console }
main() {
me.console = new ConsoleBox()
// 親クラス単独テスト
local parent
parent = new Parent()
local directValue
directValue = parent.getValue()
me.console.log("Direct Parent getValue: " + directValue)
// 子クラスから親メソッドテスト
local child
child = new Child()
local childResult
childResult = child.test()
me.console.log("Child test result: " + childResult)
return "Field access test completed"
}
}