Changeset 5646 for src/Pugs/Compile.hs
- Timestamp:
- 07/17/05 21:22:32 (3 years ago)
- Author:
- iblech
- svk:copy_cache_prev:
- 7648
- Message:
-
* Pugs.Compile -- &infix:<
>(foo, bar) is compiled as &infix:< >(foo,
PThunk(bar)) now.
* Pugs.CodeGen?.PIR -- So Pugs.CodeGen?.PIR doesn't have to do this change, as
Pugs.Compile does it now.
* Pugs.Parser -- Filtered out &infix:<,> from list of user-overridable subs, as
else even basic arglists use &infix:<,> if a &infix:<,> is defined (see
comment).
* PIL2JS: Prelude::JS -- Proper support for
, &&, etc.
* PIL2JS: README -- Minor cleanup.
- Files:
- 1 modified
-
src/Pugs/Compile.hs (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
src/Pugs/Compile.hs
r5644 r5646 329 329 invC <- maybeM (return inv) compile 330 330 argsC <- enter cxtItemAny $ compile args 331 return $ PApp cxt funC invC argsC 331 if isLogicalLazy funC 332 then return $ PApp cxt funC invC (head argsC:map PThunk (tail argsC)) 333 else return $ PApp cxt funC invC argsC 334 where 335 -- XXX HACK 336 isLogicalLazy (PExp (PVar "&infix:or")) = True 337 isLogicalLazy (PExp (PVar "&infix:and")) = True 338 isLogicalLazy (PExp (PVar "&infix:||")) = True 339 isLogicalLazy (PExp (PVar "&infix:&&")) = True 340 isLogicalLazy (PExp (PVar "&infix://")) = True 341 isLogicalLazy (PExp (PVar "&infix:err")) = True 342 isLogicalLazy _ = False 332 343 compile exp@(Syn "if" _) = compConditional exp 333 344 compile (Syn "{}" (x:xs)) = compile $ App (Var "&postcircumfix:{}") (Just x) xs
Download in other formats:
