Skip to content

Development - refactor #32

@kamil-adam

Description

@kamil-adam

Split to:

  • boot strap compiler compiled ghc
  • self hosted compiler compiled simply Haskell self hosted

Quarters: Steps for backend:

  • Full Haskell
  • Reduced Haskell (System F)
  • Untyped lambda
  • Indexed lambda
  • Terms

Terms:

  • SKI
  • SK
  • SKIBCT
  • SKIBCT and many others (APY)
  • Shit: Simple Haskell Instruction Transpiler

Steps for frontend:

  • function compiler: s -> (s, a)
  • data compiler: State s a
  • transformer compiler: StateT Maybe s a
  • Alternative / MonadPlus / MonadError compiler: StateMonad m
  • Choice / ArrowPlus / ArrowError Compiler: ArrowState s a

Projects to use:

  • hs2lazy
  • hs2bf
  • compiler quest
  • thih
  • Interpreter for Nano (condensed version of Haskell)
  • Micro Haskell
  • MiniHaskell Compiler
  • helium
  • Hugs for functions dependencies
  • MicroHs: Haskell 2010: still alive

Internal for self compiling

data World = (Stream , Stream)

# probably it will not work. we will have to use simpler structure 
data IO a = StateT World (Either String) a
# data IO a = State World (Either String a)
# type IO a = World -> ((Either String a), World)

data Parser a = StateT String (Either String) a
# data Parser a = State String (Either String a)
# type Parser a = String -> ((Either String a , String)

data RIO e a = ReaderT e IO a
# data RIO e a = Reader e (IO a)
# type RIO e a = e -> IO a

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions