feat(third_party/bazel): Check in rules_haskell from Tweag

This commit is contained in:
Vincent Ambo 2019-07-04 11:18:12 +01:00
parent 2eb1dc26e4
commit f723b8b878
479 changed files with 51484 additions and 0 deletions

View file

@ -0,0 +1,35 @@
load(
"@io_tweag_rules_haskell//haskell:haskell.bzl",
"haskell_library",
)
package(
default_testonly = 1,
default_visibility = ["//visibility:public"],
)
haskell_library(
name = "lib-a",
srcs = glob(["lib-a/*.hs"]),
hidden_modules = ["Foo"],
src_strip_prefix = "lib-a",
deps = ["//tests/hackage:base"],
)
haskell_library(
name = "lib-b",
srcs = glob(["lib-b/*.hs"]),
src_strip_prefix = "lib-b",
deps = ["//tests/hackage:base"],
)
haskell_library(
name = "lib-c",
srcs = glob(["lib-c/*.hs"]),
src_strip_prefix = "lib-c",
deps = [
":lib-a",
":lib-b",
"//tests/hackage:base",
],
)

View file

@ -0,0 +1,6 @@
module Bar (bar) where
import Foo (foo)
bar :: Int
bar = foo * 2

View file

@ -0,0 +1,4 @@
module Foo (foo) where
foo :: Int
foo = 15

View file

@ -0,0 +1,4 @@
module Foo (foo) where
foo :: Int
foo = 16

View file

@ -0,0 +1,7 @@
module Baz (bar) where
import Foo (foo)
import Bar (bar)
baz :: Int
baz = foo + bar