Changeset 14303 for src/Pugs/Eval.hs

Show
Ignore:
Timestamp:
10/12/06 23:26:57 (2 years ago)
Author:
audreyt
svk:copy_cache_prev:
21165
Message:

* Pugs.Eval: Allow "/.../" to match against $_ immediately

not only under (Bool $) context, but also (Num $), (Str $)
and () (aka void) contexts.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • src/Pugs/Eval.hs

    r14275 r14303  
    793793 
    794794reduceSyn "match" exps = do 
    795     env <- ask 
    796     let cls = envClasses env 
    797         cxt = envContext env 
    798         typ = typeOfCxt cxt 
    799     if isaType cls "Bool" typ 
     795    immediate <- isImmediateMatchContext 
     796    if immediate 
    800797        then reduceApp (_Var "&infix:~~") Nothing [Var varTopic, Syn "rx" exps] 
    801798        else reduceSyn "rx" exps