xls
xls copied to clipboard
Support proc-local functions
It'd be nice to have procs be self-contained, as objects are in OOP. IOW, it'd be nice to be able to do:
proc p {
config(...) { ... }
next(tok: token, state: state_t) {
let new_state = create_new_state(...);
}
fn create_new_state(...) -> state_t { ... }
}
That way we can "localize" concerns, rather than having to splat them all over and mix them in a impl. file.
related https://github.com/google/xls/commit/1af3c8cf8144f46be9bca6e44b98477adfe5dd8d