diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/ChangeLog | 5 | ||||
-rw-r--r-- | src/interp/Makefile.pamphlet | 5 | ||||
-rw-r--r-- | src/interp/define.boot | 24 | ||||
-rw-r--r-- | src/interp/iterator.boot | 3 | ||||
-rw-r--r-- | src/interp/nruncomp.boot | 1 |
5 files changed, 24 insertions, 14 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index d42a58e8..4500762e 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2008-11-16 Gabriel Dos Reis <gdr@cs.tamu.edu> + + * interp/define.boot: More cleanup. + * interp/iterator.boot: Likewise. + 2008-11-15 Gabriel Dos Reis <gdr@cs.tamu.edu> * interp/c-util.boot: Clean up. diff --git a/src/interp/Makefile.pamphlet b/src/interp/Makefile.pamphlet index a1dd3658..0be15564 100644 --- a/src/interp/Makefile.pamphlet +++ b/src/interp/Makefile.pamphlet @@ -555,11 +555,12 @@ compiler.$(FASLEXT): msgdb.$(FASLEXT) \ pathname.$(FASLEXT) define.$(FASLEXT) iterator.$(FASLEXT) nrunopt.$(FASLEXT): c-util.$(FASLEXT) nrunfast.$(FASLEXT): c-util.$(FASLEXT) -nruncomp.$(FASLEXT): nrunopt.$(FASLEXT) profile.$(FASLEXT) simpbool.$(FASLEXT) +nruncomp.$(FASLEXT): nrunopt.$(FASLEXT) profile.$(FASLEXT) \ + simpbool.$(FASLEXT) functor.$(FASLEXT) nrungo.$(FASLEXT): c-util.$(FASLEXT) clam.$(FASLEXT) interop.$(FASLEXT) iterator.$(FASLEXT): g-util.$(FASLEXT) define.$(FASLEXT): g-error.$(FASLEXT) modemap.$(FASLEXT) \ - functor.$(FASLEXT) nruncomp.$(FASLEXT) database.$(FASLEXT) + nruncomp.$(FASLEXT) database.$(FASLEXT) database.$(FASLEXT): clam.$(FASLEXT) nlib.$(FASLEXT) \ cattable.$(FASLEXT) compat.$(FASLEXT) g-cndata.$(FASLEXT) functor.$(FASLEXT): category.$(FASLEXT) nrungo.$(FASLEXT) lisplib.$(FASLEXT) diff --git a/src/interp/define.boot b/src/interp/define.boot index 7fb4e2d4..c32b0c07 100644 --- a/src/interp/define.boot +++ b/src/interp/define.boot @@ -34,12 +34,18 @@ import nruncomp import g_-error import database -import functor import modemap namespace BOOT -module define +module define where + compDefine: (%Form,%Mode,%Env) -> %Maybe %Triple + compSubDomain: (%Form,%Mode,%Env) -> %Maybe %Triple + compCapsule: (%Form, %Mode, %Env) -> %Maybe %Triple + compJoin: (%Form,%Mode,%Env) -> %Maybe %Triple + compAdd: (%Form, %Mode, %Env) -> %Maybe %Triple + compCategory: (%Form,%Mode,%Env) -> %Maybe %Triple + --% @@ -107,6 +113,12 @@ $atList := [] --% +compDefineAddSignature: (%Form,%Signature,%Env) -> %Env +DomainSubstitutionFunction: (%List,%Form) -> %Form + + +--% + ++ List of operations defined in a given capsule ++ Each item on this list is of the form ++ (op sig pred) @@ -157,7 +169,6 @@ makePredicate l == ++ List of packages used by the current domain. $packagesUsed := [] -compDefine: (%Form,%Mode,%Env) -> %Maybe %Triple compDefine(form,m,e) == $macroIfTrue: local := false $packagesUsed: local := [] @@ -245,7 +256,6 @@ compDefine1(form,m,e) == getAbbreviation($op,#rest $form) compDefineCapsuleFunction(form,m,e,newPrefix,$formalArgList) -compDefineAddSignature: (%Form,%Signature,%Env) -> %Env compDefineAddSignature([op,:argl],signature,e) == (sig:= hasFullSignature(argl,signature,e)) and not assoc(['$,:sig],LASSOC('modemap,getProplist(op,e))) => @@ -1358,7 +1368,6 @@ bootStrapError(functorForm,sourceFile) == [''T, ['systemError,['LIST,''%b,MKQ CAR functorForm,''%d,'"from", _ ''%b,MKQ namestring sourceFile,''%d,'"needs to be compiled"]]]] -compAdd: (%Form, %Mode, %Env) -> %Maybe %Triple compAdd(['add,$addForm,capsule],m,e) == $bootStrapMode = true => if $addForm is ["%Comma",:.] then code := nil @@ -1390,7 +1399,6 @@ compAdd(['add,$addForm,capsule],m,e) == compTuple2Record u == ['Record,:[[":",i,x] for i in 1.. for x in rest u]] -compCapsule: (%Form, %Mode, %Env) -> %Maybe %Triple compCapsule(['CAPSULE,:itemList],m,e) == $bootStrapMode = true => [bootStrapError($functorForm, _/EDITFILE),m,e] @@ -1399,7 +1407,6 @@ compCapsule(['CAPSULE,:itemList],m,e) == clearCapsuleFunctionTable() compCapsuleInner(maybeInsertViewMorphisms itemList,m,addDomain('_$,e)) -compSubDomain: (%Form,%Mode,%Env) -> %Maybe %Triple compSubDomain(["SubDomain",domainForm,predicate],m,e) == $addFormLhs: local:= domainForm $addForm: local := nil @@ -1583,7 +1590,6 @@ compContained(["CONTAINED",a,b],m,e) == (T:= [["CONTAINED",a,b],$Boolean,e]; convert(T,m)) nil -compJoin: (%Form,%Mode,%Env) -> %Maybe %Triple compJoin(["Join",:argl],m,e) == catList:= [(compForMode(x,$Category,e) or return 'failed).expr for x in argl] catList='failed => stackSemanticError(["cannot form Join of: ",argl],nil) @@ -1625,7 +1631,6 @@ makeCategoryForm(c,e) == [x,e] -compCategory: (%Form,%Mode,%Env) -> %Maybe %Triple compCategory(x,m,e) == clearExportsTable() (m:= resolve(m,$Category))=$Category and x is ['CATEGORY, @@ -1660,7 +1665,6 @@ mustInstantiate D == D is [fn,:.] and not (MEMQ(fn,$DummyFunctorNames) or GETL(fn,"makeFunctionList")) -DomainSubstitutionFunction: (%List,%Form) -> %Form DomainSubstitutionFunction(parameters,body) == --see definition of DomainSubstitutionMacro in SPAD LISP if parameters then diff --git a/src/interp/iterator.boot b/src/interp/iterator.boot index 7497b336..ab7a76d7 100644 --- a/src/interp/iterator.boot +++ b/src/interp/iterator.boot @@ -93,7 +93,7 @@ compRepeatOrCollect(form,m,e) == fn(form,[m,:$exitModeStack],[#$exitModeStack,:$leaveLevelStack],$formalArgList ,e) where fn(form,$exitModeStack,$leaveLevelStack,$formalArgList,e) == - $until: local + $until: local := nil oldEnv := e [repeatOrCollect,:itl,body]:= form itl':= @@ -117,7 +117,6 @@ compRepeatOrCollect(form,m,e) == -- then we've boobed. JHD 26.July.1990 $NoValueMode [body',m',e']:= - -- (m1:= listOrVectorElementMode targetMode) and comp(body,m1,e) or compOrCroak(body,bodyMode,e) or return nil if $until then [untilCode,.,e']:= comp($until,$Boolean,e') diff --git a/src/interp/nruncomp.boot b/src/interp/nruncomp.boot index 620bcbf0..115e57f9 100644 --- a/src/interp/nruncomp.boot +++ b/src/interp/nruncomp.boot @@ -35,6 +35,7 @@ import nrunopt import simpbool import profile +import functor namespace BOOT |