feat(cli): ludic deps - the module graph as the compiler resolved it
With LUDIC_DEPS=<file> the compiler records every reference the visibility pass resolves (from module, to module) and every assignment to another module's global. ludic deps prints the modules, dependencies, largest cycle, cross writes and globals written from outside, with --graph, --dot, --writes, --uses MOD, --check FILE and --baseline FILE. Reseed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
69352babfd
commit
e738741521
17 changed files with 44510 additions and 41589 deletions
12
examples/modules/tangle.ludic
Normal file
12
examples/modules/tangle.ludic
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
# tangle.ludic — the program `ludic deps` is tested on: a and b use each other (the largest cycle is
|
||||
# 2), both use the leaf c (not counted), and a writes b's global b_count (one cross-module write).
|
||||
#
|
||||
# Running it prints: 4
|
||||
import "tangle/c"
|
||||
import "tangle/a"
|
||||
import "tangle/b"
|
||||
program Tangle {
|
||||
entry {
|
||||
print(a_run())
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue