nyash-codex
42b09b3c1c
feat(phase88): Ring0Context Skeleton implementation
Phase 88: OS API abstraction layer implementation
**Implementation**:
- Ring0Context module added (4 files)
- mod.rs: Public API, global initialization (OnceLock)
- traits.rs: MemApi, IoApi, TimeApi, LogApi trait definitions
- std_impls.rs: std-based default implementations
- errors.rs: IoError, TimeError type definitions
**Design Principles**:
- Ring0 knows nothing about Box
- Ring0 knows nothing about Nyash
- Pure OS API abstraction
**Global Initialization**:
- NyashRunner::new() initializes Ring0Context globally
- OnceLock ensures safe initialization (idempotent)
**Migration (2 paths)**:
- src/runner/selfhost.rs:27: eprintln! → ring0.log.error() (OOB strict)
- src/runner/selfhost.rs:177: eprintln! → ring0.log.error() (PyVM error)
**Tests**:
- 4 unit tests added (ring0 module)
- All tests passed
- Build successful (0 errors)
**Migration Status**:
- Migrated: 2/3,955 (0.05%)
- Remaining: 3,953 paths (Phase 89+)
**Files Changed**:
- src/runtime/ring0/mod.rs (new, 100 lines)
- src/runtime/ring0/traits.rs (new, 93 lines)
- src/runtime/ring0/std_impls.rs (new, 77 lines)
- src/runtime/ring0/errors.rs (new, 26 lines)
- src/runtime/mod.rs (Ring0Context export)
- src/runner/mod.rs (global initialization)
- src/runner/selfhost.rs (2 paths migrated)
- docs/development/current/main/ring0-inventory.md (Phase 88 status)
Phase 88 complete. Ready for Phase 89 (gradual migration).
🐱✨
2025-12-02 22:38:27 +09:00
..
2025-09-17 10:58:12 +09:00
2025-09-17 10:58:12 +09:00
2025-09-17 10:58:12 +09:00
2025-09-17 10:58:12 +09:00
2025-12-02 22:22:32 +09:00
2025-12-02 21:52:18 +09:00
2025-11-27 17:05:46 +09:00
2025-11-27 17:05:46 +09:00
2025-11-29 15:57:14 +09:00
2025-11-29 15:57:14 +09:00
2025-11-29 15:57:14 +09:00
2025-11-30 08:54:18 +09:00
2025-12-02 09:45:54 +09:00
2025-11-30 10:10:45 +09:00
2025-12-02 10:19:07 +09:00
2025-12-02 11:16:01 +09:00
2025-12-02 12:36:28 +09:00
2025-12-02 19:37:01 +09:00
2025-12-02 19:37:01 +09:00
2025-12-02 19:37:01 +09:00
2025-12-02 19:37:01 +09:00
2025-12-02 20:18:13 +09:00
2025-12-02 20:18:13 +09:00
2025-12-02 20:18:13 +09:00
2025-12-02 20:30:22 +09:00
2025-12-02 20:18:13 +09:00
2025-12-02 19:37:01 +09:00
2025-12-02 19:37:01 +09:00
2025-12-02 21:09:15 +09:00
2025-12-02 21:09:15 +09:00
2025-11-23 05:53:27 +09:00
2025-12-02 22:38:27 +09:00
2025-11-21 07:00:05 +09:00
2025-11-21 08:03:03 +09:00
2025-11-21 08:03:03 +09:00
2025-11-20 17:10:03 +09:00
2025-11-20 17:10:03 +09:00
2025-11-20 17:10:03 +09:00