aboutsummaryrefslogtreecommitdiff
path: root/src/boot/strap
diff options
context:
space:
mode:
authordos-reis <gdr@axiomatics.org>2011-10-02 03:35:59 +0000
committerdos-reis <gdr@axiomatics.org>2011-10-02 03:35:59 +0000
commit8640c7b9aa33084d77770f435814d1d8558c8e2e (patch)
tree968ff56d45b80dcc8ad3002703025cf27995e155 /src/boot/strap
parent496ca25659180bb29cc5fea2f3c0337695d742d3 (diff)
downloadopen-axiom-8640c7b9aa33084d77770f435814d1d8558c8e2e.tar.gz
* boot/utility.boot (objectAssoc): New. Export.
* boot/ast.boot: Use it. instead of ASSOC. * boot/translator.boot (packageBody): Tidy. * interp/astr.boot: Use objectAssoc instead of ASSQ. * interp/br-con.boot: Likewise. * interp/br-op1.boot: Likewise. * interp/br-saturn.boot: Likewise. * interp/buildom.boot: Likewise. * interp/c-util.boot: Likewise. * interp/category.boot: Likewise. * interp/clam.boot: Likewise. * interp/compiler.boot: Likewise. * interp/define.boot: Likewise. * interp/functor.boot: Likewise. * interp/g-util.boot: Likewise. * interp/i-coerce.boot: Likewise. * interp/i-coerfn.boot: Likewise. * interp/i-funsel.boot: Likewise. * interp/i-object.boot: Likewise. * interp/i-output.boot: Likewise. * interp/i-resolv.boot: Likewise. * interp/i-special.boot: Likewise. * interp/i-syscmd.boot: Likewise. * interp/i-util.boot: Likewise. * interp/int-top.boot: Likewise. * interp/lisplib.boot: Likewise. * interp/msg.boot: Likewise. * interp/posit.boot: Likewise. * interp/termrw.boot: Likewise. * interp/trace.boot: Likewise. * interp/sys-utility.boot (upwardCut): New. * interp/spad.lisp: Use it. * interp/util.lisp: Likewise. * interp/spaderror.lisp: Likewise. * interp/vmlisp.lisp (ASSEMBLE): Remove. (ASSQ): Likewise. (MEMQ): Likewise. (NAMEDERRSET): Likewise. (ORADDTEMPDEFS): Likewise. * interp/macros.lisp (QLASSQ): Move to vmlisp.lisp. (LASSQ): Remove.
Diffstat (limited to 'src/boot/strap')
-rw-r--r--src/boot/strap/ast.clisp13
-rw-r--r--src/boot/strap/translator.clisp8
-rw-r--r--src/boot/strap/utility.clisp17
3 files changed, 29 insertions, 9 deletions
diff --git a/src/boot/strap/ast.clisp b/src/boot/strap/ast.clisp
index 6f4c96da..6a92bd8d 100644
--- a/src/boot/strap/ast.clisp
+++ b/src/boot/strap/ast.clisp
@@ -2448,7 +2448,9 @@
(COND ((NULL |t|) |t|)
((NOT (CONSP |t|))
(COND
- ((SETQ |t'| (CDR (ASSOC (|coreSymbol| |t|) |$NativeTypeTable|)))
+ ((SETQ |t'|
+ (CDR
+ (|objectAssoc| (|coreSymbol| |t|) |$NativeTypeTable|)))
(SETQ |t'|
(COND
((|%hasFeature| :SBCL) (|bfColonColon| 'SB-ALIEN |t'|))
@@ -3109,7 +3111,8 @@
(DEFUN |genCLISPnativeTranslation,actualArg| (|p| |pairs|)
(PROG (|a'|)
(RETURN
- (COND ((SETQ |a'| (CDR (ASSOC |p| |pairs|))) (CDR (CDR |a'|))) (T |p|)))))
+ (COND ((SETQ |a'| (CDR (|objectAssoc| |p| |pairs|))) (CDR (CDR |a'|)))
+ (T |p|)))))
(DEFUN |getCLISPType| (|a|) (LIST (|bfColonColon| 'FFI 'C-ARRAY) (LENGTH |a|)))
@@ -3255,10 +3258,12 @@
(LIST |x|
(COND
((SETQ |p'|
- (ASSOC |p| |strPairs|))
+ (|objectAssoc| |p|
+ |strPairs|))
(CDR |p'|))
((SETQ |p'|
- (ASSOC |p| |aryPairs|))
+ (|objectAssoc| |p|
+ |aryPairs|))
(CDR |p'|))
(T |p|)))))
(COND ((NULL |bfVar#13|) NIL)
diff --git a/src/boot/strap/translator.clisp b/src/boot/strap/translator.clisp
index 7ce79ebe..c39dcf5b 100644
--- a/src/boot/strap/translator.clisp
+++ b/src/boot/strap/translator.clisp
@@ -601,11 +601,9 @@
(COND ((|%hasFeature| :SBCL) 'SB-ALIEN)
((|%hasFeature| :CLISP) 'FFI)
((|%hasFeature| :CLOZURE) 'CCL)
- ((|%hasFeature| :ECL) 'EXT) ((|%hasFeature| :GCL) 'SI)
- (T NIL)))
- ((|ident?| |ns|) |ns|) (T NIL)))
- (COND ((NULL |z|) (|bpTrap|))
- (T (CONS 'USE-PACKAGE (CONS (SYMBOL-NAME |z|) |user|)))))))
+ ((|%hasFeature| :ECL) 'FFI) (T (RETURN NIL))))
+ ((|ident?| |ns|) |ns|) (T (|bpTrap|))))
+ (CONS 'USE-PACKAGE (CONS (SYMBOL-NAME |z|) |user|)))))
((AND (CONSP |x|) (EQ (CAR |x|) 'PROGN))
(CONS (CAR |x|)
(LET ((|bfVar#2| NIL)
diff --git a/src/boot/strap/utility.clisp b/src/boot/strap/utility.clisp
index 8a06ff0c..7125bd09 100644
--- a/src/boot/strap/utility.clisp
+++ b/src/boot/strap/utility.clisp
@@ -48,6 +48,12 @@
(FTYPE (FUNCTION ((|%List| |%Thing|) |%Thing|) (|%List| |%Thing|)) |remove|))
(DECLAIM
+ (FTYPE
+ (FUNCTION (|%Thing| (|%List| (|%Pair| |%Thing| |%Thing|)))
+ (|%Maybe| (|%Pair| |%Thing| |%Thing|)))
+ |objectAssoc|))
+
+(DECLAIM
(FTYPE (FUNCTION ((|%List| |%Thing|) (|%List| |%Thing|)) (|%List| |%Thing|))
|setDifference|))
@@ -329,6 +335,17 @@
((OR (CHARACTERP |x|) (INTEGERP |x|)) (|removeScalar| |l| |x|))
(T (|removeValue| |l| |x|))))
+(DEFUN |objectAssoc| (|x| |l|)
+ (PROG (|a| |p|)
+ (RETURN
+ (LOOP
+ (COND
+ ((NOT
+ (AND (CONSP |l|) (PROGN (SETQ |p| (CAR |l|)) (SETQ |l| (CDR |l|)) T)))
+ (RETURN NIL))
+ ((AND (CONSP |p|) (PROGN (SETQ |a| (CAR |p|)) T) (EQ |a| |x|))
+ (RETURN |p|)))))))
+
(DEFUN |charPosition| (|c| |s| |k|)
(PROG (|n|)
(RETURN