aboutsummaryrefslogtreecommitdiff
path: root/src/interp
diff options
context:
space:
mode:
Diffstat (limited to 'src/interp')
-rw-r--r--src/interp/define.boot1
-rw-r--r--src/interp/lisplib.boot18
2 files changed, 18 insertions, 1 deletions
diff --git a/src/interp/define.boot b/src/interp/define.boot
index 72014231..873ee80e 100644
--- a/src/interp/define.boot
+++ b/src/interp/define.boot
@@ -1381,6 +1381,7 @@ compDefineFunctor1(df is ['DEF,form,signature,body],
dbConstructorForm(db) := form
dbCompilerData(db) := makeCompilationData()
dbFormalSubst(db) := pairList(form.args,$FormalMapVariableList)
+ dbTemplate(db) := nil
deduceImplicitParameters(db,$e)
$formalArgList:= [:argl,:$formalArgList]
-- all defaulting packages should have caching turned off
diff --git a/src/interp/lisplib.boot b/src/interp/lisplib.boot
index 9866b245..9449eff4 100644
--- a/src/interp/lisplib.boot
+++ b/src/interp/lisplib.boot
@@ -469,7 +469,22 @@ writeInfo(ctor,info,key,prop,file) ==
insn := ['%store,[prop,mkCtorDBForm ctor],quote info]
LAM_,FILEACTQ(key,expandToVMForm insn)
lisplibWrite(symbolName key,info,file)
-
+
+++ Like writeInfo, but only write to the load unit.
+writeLoadInfo(ctor,info,key,prop,file) ==
+ info = nil => nil
+ insn := ['%store,[prop,mkCtorDBForm ctor],info]
+ LAM_,FILEACTQ(key,expandToVMForm insn)
+
+literalData x ==
+ x = nil => nil
+ quote x
+
+writeTemplate(db,file) ==
+ dbConstructorKind db = 'category => nil
+ writeLoadInfo(dbConstructor db,literalData dbTemplate db,
+ 'template,'dbTemplate,file)
+
writeKind(ctor,kind,file) ==
writeInfo(ctor,kind,'constructorKind,'dbConstructorKind,file)
@@ -525,6 +540,7 @@ finalizeLisplib(ctor,libName) ==
kind := dbConstructorKind db
form := dbConstructorForm db
mm := getConstructorModemap ctor
+ writeTemplate(db,$libFile)
writeConstructorForm(ctor,form,$libFile)
writeKind(ctor,kind,$libFile)
writeConstructorModemap(ctor,mm,$libFile)