From 9dd271504160b624284dbc438cdc867b6ca0d0e7 Mon Sep 17 00:00:00 2001 From: pacien Date: Sun, 5 Jan 2020 16:24:02 +0100 Subject: compiler: enable warnings and fix them GitHub: fixes #9 --- compiler/src/Files.hs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'compiler/src/Files.hs') diff --git a/compiler/src/Files.hs b/compiler/src/Files.hs index 53f9c9e..291a1c5 100644 --- a/compiler/src/Files.hs +++ b/compiler/src/Files.hs @@ -34,9 +34,9 @@ module Files ) where -import Control.Monad (filterM, mapM) +import Control.Monad (mapM) import Data.Bool (bool) -import Data.List (isPrefixOf, length, deleteBy, subsequences) +import Data.List (isPrefixOf, length, subsequences) import Data.Function ((&)) import Data.Text (pack) import Data.Aeson (ToJSON) @@ -80,6 +80,7 @@ file /> (Path path) = Path (path ++ [file]) (<.>) :: Path -> String -> Path (Path (filename:pathto)) <.> ext = Path $ System.FilePath.addExtension filename ext : pathto +(Path _) <.> ext = Path [ext] fileName :: Path -> Maybe FileName fileName (Path (name:_)) = Just name -- cgit v1.2.3