mirror of
https://github.com/digital-asset/daml.git
synced 2024-09-20 09:17:43 +03:00
712231c963
Instead of importing _all_ other modules referenced from a module, only import those that are actually referenced from the generated code. First, this produces less noise within each generated file. Second and probably more important, this allows for not generating files without any actual definition at all. https://github.com/digital-asset/davl/pull/81 demonstrates the effect of this change on DAVL.
30 lines
701 B
Python
30 lines
701 B
Python
# Copyright (c) 2019 The DAML Authors. All rights reserved.
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
load("//bazel_tools:haskell.bzl", "da_haskell_binary")
|
|
|
|
da_haskell_binary(
|
|
name = "daml2ts",
|
|
srcs = glob(["src/**/*.hs"]),
|
|
hackage_deps = [
|
|
"base",
|
|
"bytestring",
|
|
"containers",
|
|
"directory",
|
|
"extra",
|
|
"filepath",
|
|
"lens",
|
|
"optparse-applicative",
|
|
"text",
|
|
"zip-archive",
|
|
],
|
|
src_strip_prefix = "src",
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
"//compiler/daml-lf-ast",
|
|
"//compiler/daml-lf-proto",
|
|
"//compiler/daml-lf-reader",
|
|
"//libs-haskell/da-hs-base",
|
|
],
|
|
)
|