author: Julien Moutinho -- bug-reports: http://doc.autogeree.net/lol/bugs build-type: Simple cabal-version: >= 1.10 category: Language -- data-dir: data -- data-files: description: Library gathering important ideas from the approach to Embedded DSL (Domain-Specific Language) developed by Jacques Carette, Oleg Kiselyov and Chung-chieh Shan, and pursuing this work to use it as a non-Embedded DSL. . A so-called /symantic/ type class defines a /syntax/ and each of its instances defines a new /semantic/ (computing a Haskell term, serializing, optimizing, …). . Combining the methods of those /symantic/ type classes gives rise to a DSL within which one can write /symantic/ expressions at developing time; but in order to handle such expression when entered by an end-user, one has to be able to construct it at runtime. . This library (including its Test.hs files) demonstrates this for a few usual types and methods, by: . * Parsing a /symantic/ expression from an AST (Abstract Syntax Tree). . * Removing or adding /symantic/ parsers by fully reusing old parsers (i.e. without copying or alterating them). . * Interpreting a /symantic/ expression multiple times and with different interpreters without reparsing the expression. . Hence, one can select all or a few expressions (and associated types) of this library, add its own, parse them at runtime from its own AST, and then interpret them at will. . Your comments, problem reports, or questions are very welcome! :-) extra-source-files: extra-tmp-files: -- homepage: http://pad.autogeree.net/informatique/lol/symantic/ license: GPL-3 license-file: COPYING maintainer: Julien Moutinho name: lol-symantic stability: experimental synopsis: Typed Tagless-Final Higher-Order Extensible DSL tested-with: GHC==7.10.3 version: 1.20161008 Source-Repository head location: git://git.autogeree.net/lol type: git Flag dev Default: False Description: Turn on development settings. Manual: True Flag dump Default: False Description: Dump some intermediate files. Manual: True Flag prof Default: False Description: Turn on profiling settings. Manual: True Flag threaded Default: False Description: Enable threads. Manual: True Library default-extensions: ghc-options: -Wall -fno-warn-tabs if flag(dev) cpp-options: -DDEVELOPMENT ghc-options: -- -ddump-splices -- -fno-warn-unused-do-bind -fno-warn-name-shadowing -fno-warn-missing-signatures -- -fno-warn-type-defaults -fno-warn-orphans if flag(dump) ghc-options: -ddump-simpl -ddump-stg -ddump-to-file if flag(prof) cpp-options: -DPROFILING ghc-options: -fprof-auto default-language: Haskell2010 exposed-modules: Language.LOL.Symantic Language.LOL.Symantic.Expr Language.LOL.Symantic.Expr.Bool Language.LOL.Symantic.Expr.Common Language.LOL.Symantic.Expr.Int Language.LOL.Symantic.Expr.Lambda Language.LOL.Symantic.Expr.Maybe Language.LOL.Symantic.Expr.If Language.LOL.Symantic.Expr.Eq Language.LOL.Symantic.Expr.Ord Language.LOL.Symantic.Lib.Control.Monad Language.LOL.Symantic.Lib.Data.Peano Language.LOL.Symantic.Repr Language.LOL.Symantic.Repr.Dup Language.LOL.Symantic.Repr.Host Language.LOL.Symantic.Repr.Text Language.LOL.Symantic.Trans Language.LOL.Symantic.Trans.Bool Language.LOL.Symantic.Trans.Bool.Const Language.LOL.Symantic.Trans.Common Language.LOL.Symantic.Type Language.LOL.Symantic.Type.Unit Language.LOL.Symantic.Type.Bool Language.LOL.Symantic.Type.Common Language.LOL.Symantic.Type.Fun Language.LOL.Symantic.Type.Int Language.LOL.Symantic.Type.Maybe Language.LOL.Symantic.Type.Var -- Language.LOL.Symantic.Expr.Ordering build-depends: base >= 4.6 && < 5 , ghc-prim , monad-classes >= 0.3.1.1 , transformers , text Test-Suite lol-symantic-test type: exitcode-stdio-1.0 default-extensions: OverloadedStrings default-language: Haskell2010 ghc-options: -Wall -fno-warn-tabs -main-is Test hs-source-dirs: Language/LOL/Symantic main-is: Test.hs other-modules: AST.Test Expr.Bool.Test Expr.Eq.Test Expr.If.Test Expr.Int.Test Expr.Lambda.Test Expr.Maybe.Test Expr.Test Repr.Host.Test Repr.Test Repr.Text.Test Trans.Bool.Const.Test Trans.Bool.Test Trans.Test Type.Test if flag(threaded) ghc-options: -threaded -rtsopts -with-rtsopts=-N if flag(dev) cpp-options: -DDEVELOPMENT ghc-options: if flag(prof) cpp-options: -DPROFILING ghc-options: -fprof-auto build-depends: base >= 4.6 && < 5 , transformers , tasty >= 0.11 , tasty-hunit , text , lol-symantic