The language corpus
Faber 语言语料库是公开的语言词典:每个关键字、运算符组或语言类型表面各占一个顶级目录。它是 faber explain 的开发来源,也是多目标编译矩阵的主要输入。
统计#
- 292 个
.fab示例文件 index.toml中有 174 个注册条目- 约 135 个关键字和概念目录
布局#
corpus/
functio/ # function keyword exemplars
genus/ # record type exemplars
si/ # conditional branch exemplars
itera/ # iteration exemplars
lista/ tabula/ # collection type exemplars
tensor/ sparsa/ # tensor exemplars
ad/ # capability call exemplars
operatores/ # glyph / operator groups
...
index.toml # generated explain manifest文件格式#
每个 .fab 文件以 TOML frontmatter 开头,用于描述该条目:
+++
term = "functio"
kind = "keyword"
category = "function"
canonical = true
summary = "Declares a named function or method."
syntax = "functio <name>(<params>) [modifiers] [→ <type>] [⇥ <error-type>] <block>"
aliases = ["function"]
related = ["→", "⇥", "redde", "sponte"]
+++
functio saluta() {
nota "Salve, Mundus!"
}用法#
faber explain functio # show keyword reference
faber explain ≡ # show glyph reference
faber explain --search query # search across corpus
faber explain --list # list all terms类别#
条目按类别组织:function、control-flow、type、collection、transfer、annotation、iteration、destructuring、testing、cli、concept、operator-group、existing-home。