Commit b4674ad
committed
fix(docs): respect per-binding #[cfg] feature gates in generated docs
`alef docs` rendered the full extracted API surface without evaluating a
binding's effective feature set, so feature-restricted bindings (e.g. wasm,
whose `wasm-target` excludes `tree-sitter`) documented gated types, fields,
enum variants, and functions that are compiled out of the real binding.
`generate_lang_doc` now filters the surface through the new
`ApiSurface::with_cfg_filtered_deep`, which drops cfg-gated members
(fields/variants) as well as top-level items, using each backend's real
effective feature set (Swift/Dart force-enable every cfg-referenced feature
minus `excluded_default_features`; other backends use their configured list).
`cfg_feature_satisfied` gains three-valued (Kleene) evaluation with full
all/any/not and nested-predicate support, and keeps items whose gate depends
on an unresolved non-feature leaf (e.g. target_arch).
Bumps version to 0.36.1.1 parent 4a1fec9 commit b4674ad
9 files changed
Lines changed: 529 additions & 33 deletions
File tree
- schemas
- src
- core
- ir
- docs
- language_pages
- tests
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
10 | 30 | | |
11 | 31 | | |
12 | 32 | | |
| |||
1065 | 1085 | | |
1066 | 1086 | | |
1067 | 1087 | | |
1068 | | - | |
| 1088 | + | |
1069 | 1089 | | |
1070 | 1090 | | |
1071 | 1091 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7481 | 7481 | | |
7482 | 7482 | | |
7483 | 7483 | | |
7484 | | - | |
| 7484 | + | |
7485 | 7485 | | |
7486 | 7486 | | |
7487 | 7487 | | |
| |||
7599 | 7599 | | |
7600 | 7600 | | |
7601 | 7601 | | |
7602 | | - | |
7603 | | - | |
| 7602 | + | |
| 7603 | + | |
7604 | 7604 | | |
0 commit comments