Changeset 3444

Show
Ignore:
Timestamp:
05/19/05 18:19:24 (4 years ago)
Author:
iblech
svk:copy_cache_prev:
5016
Message:

warn() implemented.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • src/Pugs/Prim.hs

    r3428 r3444  
    262262    strs <- fromVal v 
    263263    fail (concat strs) 
     264op1 "warn" = \v -> do 
     265    strs <- fromVal v 
     266    errh <- readVar "$*ERR" 
     267    pos  <- asks envPos 
     268    op2 "print" errh $ VList [ VStr $ pretty (VError strs (NonTerm pos)) ++ "\n" ] 
    264269op1 "exit" = op1Exit 
    265270op1 "readlink" = \v -> do 
     
    11161121\\n   Bool      pre     close   (Socket)\ 
    11171122\\n   Bool      pre     die     (List)\ 
     1123\\n   Bool      pre     warn    (List)\ 
    11181124\\n   IO        pre     open    (Str)\ 
    11191125\\n   Socket    pre     listen  (Int)\