Commit 48ae1d0
fix: spec2cli excludes undiscoverable interfaces and validates against Go source
Three codegen fixes:
1. Sub-interfaces (returned by methods on other interfaces but not
registered with ServiceManager) are excluded from CLI commands.
Previously generated 1708 top-level commands; most were for
interfaces that could never be discovered. Now only generates
commands for interfaces with known service mappings or that are
directly registered.
2. Unknown types (no Go struct/enum/interface exists) now return
kindUnsupported instead of kindJSONFallback, preventing generation
of code referencing undefined types like android.FileDescriptor
or accessibilityservice.AccessibilityEvent.
3. Out-direction params are passed as zero values instead of requiring
CLI flags, matching the Go proxy signatures that include out params
as input parameters.
Additional: validates generated commands against Go source to skip
interfaces/methods whose proxy constructors or method signatures
don't match the specs.1 parent 95654ec commit 48ae1d0
3 files changed
Lines changed: 122604 additions & 523932 deletions
| Original file line number | Diff line number | Diff line change |
|---|
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 |
|---|
0 commit comments