test: green up after Phase 2 merge for #26\n\n- Fix AST tests (is_override)\n- Align MIR builder test with current If AST\n- Adjust ResultBox API usage in tests\n- Add len() helpers to ArrayBox/BufferBox for tests
This commit is contained in:
@ -48,6 +48,11 @@ impl ArrayBox {
|
||||
pub fn length(&self) -> Box<dyn NyashBox> {
|
||||
Box::new(IntegerBox::new(self.items.lock().unwrap().len() as i64))
|
||||
}
|
||||
|
||||
/// Rust向けヘルパー: 要素数をusizeで取得(テスト用)
|
||||
pub fn len(&self) -> usize {
|
||||
self.items.lock().unwrap().len()
|
||||
}
|
||||
|
||||
/// インデックスで要素を取得
|
||||
pub fn get(&self, index: Box<dyn NyashBox>) -> Box<dyn NyashBox> {
|
||||
@ -302,4 +307,4 @@ impl NyashBox for ArrayBox {
|
||||
BoolBox::new(false)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user