Skip to content

Text 与 Crypto ​

Text ​

实现状态: Fmt / Regex / Encoding / StringBuilder / Bytes 薄封装 已实现。

类型典型 API
Fmtprint / printLine / debug 取 Sendable;format(..., args: Array<Sendable>)(R-12;≠ Object)
RegexisMatch / findAll / replaceAll
Encodingbase64Encode / hexEncode
Bytes / StringBuilder缓冲拼接

字符串内置方法(split、matches)仍走 CORE,不必 import Text。

Crypto ​

实现状态: Crypto.sha256 等 已实现(Host)。动态插件另见 examples/plugin_demo 与 语言指南 · 运行时扩展。

swift
import Crypto

func main() {
    print(Crypto.sha256("data"))
}

其它嵌入包(短) ​

包要点
Testingassert / assertEq(Sendable,Sendable) / test(fn: Function)(import Testing;R-12)
DIService DI;见 examples/service_di
SQLSqlRow 访问器 row: Dictionary(R-11);见 examples/sql_tool
SynchronizationChannel / Mutex / Semaphore
UISynUI 桥;deferred,勿当产品 GUI
Tracing / Metrics / Profiling可观测 MVP;非产品 OTel / Prometheus / pprof GA

SYX · Apache-2.0