diff options
author | dos-reis <gdr@axiomatics.org> | 2010-05-25 05:55:12 +0000 |
---|---|---|
committer | dos-reis <gdr@axiomatics.org> | 2010-05-25 05:55:12 +0000 |
commit | dd99f144ce50c2c3d2a1e1685a2d74ff533f6535 (patch) | |
tree | 51dbaca6e9ae15b2dda5cf5ecab88655f629cbca /src/interp/i-map.boot | |
parent | d08100e5c7cc7ebf2c30c490033f1ccd5b57fb86 (diff) | |
download | open-axiom-dd99f144ce50c2c3d2a1e1685a2d74ff533f6535.tar.gz |
* interp/g-util.boot: Implement expansion of %collect forms.
* interp/c-util.boot (middleEndExpand): Tidy.
* interp/g-opt.boot (changeThrowToExit): Don't look into %collect
forms.
* interp/i-map.boot (getUserIdentifiersIn): Factorize. Handle
%collect forms same as COLLECT forms.
(findLocalVars1): Likewise.
* interp/i-spec1.boot (evalCOLLECT): Now generate %collect forms.
(checkForFreeVariables): Factorize. Handle %collect forms same as
COLLECT forms.
Diffstat (limited to 'src/interp/i-map.boot')
-rw-r--r-- | src/interp/i-map.boot | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/interp/i-map.boot b/src/interp/i-map.boot index 331c54fa..9bb6bf4e 100644 --- a/src/interp/i-map.boot +++ b/src/interp/i-map.boot @@ -230,7 +230,7 @@ getUserIdentifiersIn body == body="" => nil [body] body is ["WRAPPED",:.] => nil - (body is ["COLLECT",:itl,body1]) or (body is ['REPEAT,:itl,body1]) => + body is [op,:itl,body1] and op in '(COLLECT REPEAT %collect) => userIds := S_+(getUserIdentifiersInIterators itl,getUserIdentifiersIn body1) S_-(userIds,getIteratorIds itl) @@ -1031,7 +1031,7 @@ findLocalVars1(op,form) == form is ['is,l,pattern] => findLocalVars1(op,l) for var in listOfVariables rest pattern repeat mkLocalVar(op,var) - form is [oper,:itrl,body] and oper in '(REPEAT COLLECT) => + form is [oper,:itrl,body] and oper in '(REPEAT COLLECT %collect) => findLocalsInLoop(op,itrl,body) form is [y,:argl] => y is "Record" or (y is "Union" and argl is [[":",.,.],:.]) => |