summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoreliaslfox <>2018-12-08 08:00:00 (GMT)
committerhdiff <hdiff@hdiff.luite.com>2018-12-08 08:00:00 (GMT)
commitee0f4559c78457969f0c2c11f6632b12fd280dfb (patch)
treeef49375cb0c6a68ad8680a673ba0d19d00eddad7
parent9c9bb96036dace17c558dd7944f0a61ed7668b13 (diff)
version 0.2.0.0HEAD0.2.0.0master
-rw-r--r--language-elm.cabal11
-rw-r--r--src/Elm.hs14
-rw-r--r--src/Elm/Declaration.hs (renamed from src/Elm/Decleration.hs)2
-rw-r--r--src/Elm/Program.hs2
-rw-r--r--test/Spec.hs2
5 files changed, 15 insertions, 16 deletions
diff --git a/language-elm.cabal b/language-elm.cabal
index e6ad9cf..d7753ff 100644
--- a/language-elm.cabal
+++ b/language-elm.cabal
@@ -2,10 +2,10 @@
--
-- see: https://github.com/sol/hpack
--
--- hash: 5a8ac7a0d3b4256acbac6f6a2752b4d850e3c26442dc066788cbb63c41b5e56e
+-- hash: 050e863d71a7e857420f7de3b152deaef3a5bb95ea66f88027aea574e710783e
name: language-elm
-version: 0.1.1.3
+version: 0.2.0.0
synopsis: Generate elm code
description: Generate elm code from an ast
category: Web
@@ -37,7 +37,7 @@ source-repository head
library
exposed-modules:
Elm
- Elm.Decleration
+ Elm.Declaration
Elm.Expression
Elm.Import
Elm.Program
@@ -50,7 +50,7 @@ library
src
build-depends:
MissingH
- , base >=4.11 && <5
+ , base >=4.11 && <4.12
, mtl
, pretty
, protolude
@@ -68,8 +68,7 @@ test-suite language-elm-test
test
ghc-options: -threaded -rtsopts -with-rtsopts=-N
build-depends:
- base >=4.11 && <5
- , doctest
+ base >=4.11 && <4.12
, hspec
, language-elm
, mtl
diff --git a/src/Elm.hs b/src/Elm.hs
index dc907bb..9f60085 100644
--- a/src/Elm.hs
+++ b/src/Elm.hs
@@ -28,7 +28,7 @@ module Elm
, ttuple
, trecord
, trecordParam
- -- * Declerations
+ -- * Declarations
, Dec
, decVariable
, decFunction
@@ -61,7 +61,7 @@ import Protolude hiding (Type, bool, list)
import Control.Monad.Writer
import Data.String
import Elm.Classes
-import qualified Elm.Decleration
+import qualified Elm.Declaration
import qualified Elm.Expression
import Elm.GenError (GenError (WarningList))
import qualified Elm.Import
@@ -72,7 +72,7 @@ import Prelude (error)
type Expr = Elm.Expression.Expr
type Type = Elm.Type.TypeDec
-type Dec = Elm.Decleration.Dec
+type Dec = Elm.Declaration.Dec
type Import = Elm.Import.Import
type ImportExpr = Elm.Import.ImportType
type ImportItem = Elm.Import.ImportItem
@@ -231,7 +231,7 @@ decVariable :: String -- ^ The variable name
-> Type -- ^ The variable's type
-> Expr -- ^ The variable's value
-> Dec
-decVariable name type_ expr = Elm.Decleration.Dec name type_ [] expr
+decVariable name type_ expr = Elm.Declaration.Dec name type_ [] expr
-- | Declare a function
decFunction :: String -- ^ The function name
@@ -239,21 +239,21 @@ decFunction :: String -- ^ The function name
-> [Expr] -- ^ The fuction's paramaters
-> Expr -- ^ The function's value
-> Dec
-decFunction = Elm.Decleration.Dec
+decFunction = Elm.Declaration.Dec
-- | Declare a type
decType :: String -- ^ The type name
-> [String] -- ^ The type's type paramaters
-> [(String, [Type])] -- ^ The type's constructors
-> Dec
-decType = Elm.Decleration.DecType
+decType = Elm.Declaration.DecType
-- | Declare a type alias
decTypeAlias :: String -- ^ The type alias' name
-> [String] -- ^ The type alias's type paramaters
-> Type -- ^ The type alias's type
-> Dec
-decTypeAlias = Elm.Decleration.DecTypeAlias
+decTypeAlias = Elm.Declaration.DecTypeAlias
-- | Import an item
select :: String -> ImportItem
diff --git a/src/Elm/Decleration.hs b/src/Elm/Declaration.hs
index 5d1037c..94b815e 100644
--- a/src/Elm/Decleration.hs
+++ b/src/Elm/Declaration.hs
@@ -4,7 +4,7 @@
{-# LANGUAGE Safe #-}
-- | Top level declerations
-module Elm.Decleration where
+module Elm.Declaration where
import Elm.Classes
import Elm.Expression
diff --git a/src/Elm/Program.hs b/src/Elm/Program.hs
index d06a678..8e8aed2 100644
--- a/src/Elm/Program.hs
+++ b/src/Elm/Program.hs
@@ -14,7 +14,7 @@ import Data.List hiding (map)
import Data.String
import Data.String.Utils
import Elm.Classes
-import Elm.Decleration
+import Elm.Declaration
import Elm.GenError
import Elm.Import
import Text.PrettyPrint
diff --git a/test/Spec.hs b/test/Spec.hs
index b7b2252..ef41bdd 100644
--- a/test/Spec.hs
+++ b/test/Spec.hs
@@ -2,7 +2,7 @@
import Control.Monad.Writer
import Elm.Classes
-import Elm.Decleration
+import Elm.Declaration
import Elm.Expression
import Elm.GenError
import Elm.Import