feat(stdlib): format all value types and expose handle identity members

- Add read-only FunctionRef.module/name and PluginHandle.plugin/export
  members; PluginHandle.id stays private (ADR-0029).
- Extend stdlib/format.mq.md to Formula/Code/FunctionRef/PluginHandle/
  Memory/Resource/Unit, with UTF-8 byte length for Code.
- Fix two-digit ordered-list body indentation so arms 10+ stay inside their
  branch (they were previously top-level statements).
- Extend stdlib demo to Formula/Code/FunctionRef and assert all three
  io.写值/打印 pairs match byte-for-byte.
- Add runtime member observation test, ADR-0029, spec/status/changelog/evidence.

Gate: fmt, clippy -D warnings, 416 tests passed.
This commit is contained in:
cflmy committed 2026-11-20 21:57:04 +08:00
1 parent 1377af1601
commit e119727c5d
14 files changed
+334 -15

No files matched your search

+21 -1
View File
@@ -3,8 +3,22 @@ import:
io: "./io.mq.md"
---
## 演示函数
*1*
## main
### 公式
$$a = 1$$
### 代码
```text
print(1)
```
**列表 = ["文本", 2, 1.5, [3, true], {a: 1, b: "x"}, None]**
> io.写值(列表)
@@ -17,4 +31,10 @@ import:
> 打印(表格)
*[类型(列表), 类型(表格)]*
**特殊 = [ref("#公式"), ref("#代码"), ref("#演示函数")]**
> io.写值(特殊)
> 打印(特殊)
*None*