daml/daml-lf/interface
Stefano Baghino 9d6eecaa4f
Refactoring codegen (#13439)
* Remove unused `name` field from `InterfaceTreeBuilder`, inline builder construction

* Remove unused `Traverse` instance for `TypeDeclOrTemplateWrapper`

* Remove unneccessary type parameter from `TypeDeclOrTemplateWrapper`

* Remove some unnecessary copies `.toList`

* Remove `TypeDeclOrTemplateWrapper`, use `Either` directly as a wrapper

* Use `bimap` instead of explicitly wrapping and unwrapping the `Either`

* Remove unnecessary type `Mode`

* Remove unnecessary type parameter from `WriteParams`

* Remove unnecessary binding

* Pull `OrderedDependencies` out of `Graph`

* Move computation of relevant packages to `codegen-common`

* Move `templateCount` from `LFUtil` into `CodeGen`

* Comment the purpose of `TransitiveClosure`

* Pull the variance cache out of `LFUtil`

`LFUtil`'s purpose is that of limiting passing around certain
values. While the purpose is questionable, the variance cache did
not need to access any of those values and it's quite easy to
move to a separate class where the purpose and the scope are clearer.

* Make `DependencyGraph` work directly on type declarations

* Add constructor for a collection of interfaces to `EnvironmentInterfaces`

* Factor the error message from `cyclicDependencies` out of `DependencyGraph`

changelog_begin
changelog_end
2022-03-29 16:29:22 +02:00
..
src Refactoring codegen (#13439) 2022-03-29 16:29:22 +02:00
BUILD.bazel interface support in the interface library (#13154) 2022-03-15 19:34:54 +00:00