Changeset 4655 for src/Pugs/Compile.hs

Show
Ignore:
Timestamp:
06/14/05 23:42:15 (3 years ago)
Author:
autrijus
svk:copy_cache_prev:
6394
Message:

* PAST compileation and PIR emission, phase 1, works! Try this,

which generates, according to Leo, "100% correct" PIR:

% ./pugs -C PIR -e 'say "Hello, World!"'
% parrot dump.ast
Hello, World!

* Also because it's now a Proper Compiler, we have this now:

% ./pugs -C PIR -e '"Hello, World!"'
*** Literal value used in constant expression: VStr "Hello, World!"

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • src/Pugs/Compile.hs

    r4149 r4655  
    1616import Pugs.Compile.Pugs2 (genPugs2) 
    1717import Pugs.Compile.Parrot (genPIR) 
     18import Pugs.Compile.PIR (genPIR') 
    1819import Pugs.Compile.Haskell (genGHC) 
    1920 
     
    2324compile "Pugs2"   env = fmap vCast $ runEvalIO env genPugs2 
    2425compile "Parrot"  env = fmap vCast $ runEvalIO env genPIR 
     26compile "Pir"     env = fmap vCast $ runEvalIO env genPIR' 
     27compile "PIR"     env = fmap vCast $ runEvalIO env genPIR' 
    2528compile s _ = fail $ "Cannot compile to " ++ s 
    2629