diff options
Diffstat (limited to 'third_party/bazel/rules_haskell/tests/extra-source-files/FooTH.hs')
-rw-r--r-- | third_party/bazel/rules_haskell/tests/extra-source-files/FooTH.hs | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/third_party/bazel/rules_haskell/tests/extra-source-files/FooTH.hs b/third_party/bazel/rules_haskell/tests/extra-source-files/FooTH.hs new file mode 100644 index 000000000000..24d663108355 --- /dev/null +++ b/third_party/bazel/rules_haskell/tests/extra-source-files/FooTH.hs @@ -0,0 +1,12 @@ +{-# LANGUAGE TemplateHaskell #-} + +module FooTH (embedFile) where + +import Language.Haskell.TH +import Language.Haskell.TH.Syntax + +embedFile :: FilePath -> Q Exp +embedFile path = do + str <- runIO (readFile path) + addDependentFile path + [| str |] |