aboutsummaryrefslogtreecommitdiffstats
path: root/Lisp/moxie
diff options
context:
space:
mode:
Diffstat (limited to 'Lisp/moxie')
-rw-r--r--Lisp/moxie/Map_Sym.txt1956
-rw-r--r--Lisp/moxie/Mop_Sym.txt128
-rw-r--r--Lisp/moxie/clhs-lookup.lisp148
-rw-r--r--Lisp/moxie/compat/compat-clisp.lib17
-rw-r--r--Lisp/moxie/compat/compat-clisp.lisp24
-rw-r--r--Lisp/moxie/compat/compat-openmcl.lisp59
-rw-r--r--Lisp/moxie/compat/compat-sbcl.faslbin0 -> 16205 bytes
-rw-r--r--Lisp/moxie/compat/compat-sbcl.lisp49
-rw-r--r--Lisp/moxie/default.faslbin0 -> 13599 bytes
-rw-r--r--Lisp/moxie/default.lisp63
-rw-r--r--Lisp/moxie/events.faslbin0 -> 26963 bytes
-rw-r--r--Lisp/moxie/events.lisp100
-rw-r--r--Lisp/moxie/hooks.lisp21
-rw-r--r--Lisp/moxie/moxie.asd34
-rw-r--r--Lisp/moxie/moxie.faslbin0 -> 41390 bytes
-rw-r--r--Lisp/moxie/moxie.lisp218
-rw-r--r--Lisp/moxie/package.faslbin0 -> 3386 bytes
-rw-r--r--Lisp/moxie/package.lisp21
-rw-r--r--Lisp/moxie/repl.faslbin0 -> 22375 bytes
-rw-r--r--Lisp/moxie/repl.lisp95
-rw-r--r--Lisp/moxie/repl.lisp.old87
-rw-r--r--Lisp/moxie/utils/bjc-utils.faslbin0 -> 41488 bytes
-rw-r--r--Lisp/moxie/utils/bjc-utils.lisp185
-rw-r--r--Lisp/moxie/world.faslbin0 -> 42872 bytes
-rw-r--r--Lisp/moxie/world.lisp120
25 files changed, 3325 insertions, 0 deletions
diff --git a/Lisp/moxie/Map_Sym.txt b/Lisp/moxie/Map_Sym.txt
new file mode 100644
index 0000000..eb1a000
--- /dev/null
+++ b/Lisp/moxie/Map_Sym.txt
@@ -0,0 +1,1956 @@
+&ALLOW-OTHER-KEYS
+../Body/03_da.htm
+&AUX
+../Body/03_da.htm
+&BODY
+../Body/03_dd.htm
+&ENVIRONMENT
+../Body/03_dd.htm
+&KEY
+../Body/03_da.htm
+&OPTIONAL
+../Body/03_da.htm
+&REST
+../Body/03_da.htm
+&WHOLE
+../Body/03_dd.htm
+*
+../Body/a_st.htm
+**
+../Body/v__stst_.htm
+***
+../Body/v__stst_.htm
+*BREAK-ON-SIGNALS*
+../Body/v_break_.htm
+*COMPILE-FILE-PATHNAME*
+../Body/v_cmp_fi.htm
+*COMPILE-FILE-TRUENAME*
+../Body/v_cmp_fi.htm
+*COMPILE-PRINT*
+../Body/v_cmp_pr.htm
+*COMPILE-VERBOSE*
+../Body/v_cmp_pr.htm
+*DEBUG-IO*
+../Body/v_debug_.htm
+*DEBUGGER-HOOK*
+../Body/v_debugg.htm
+*DEFAULT-PATHNAME-DEFAULTS*
+../Body/v_defaul.htm
+*ERROR-OUTPUT*
+../Body/v_debug_.htm
+*FEATURES*
+../Body/v_featur.htm
+*GENSYM-COUNTER*
+../Body/v_gensym.htm
+*LOAD-PATHNAME*
+../Body/v_ld_pns.htm
+*LOAD-PRINT*
+../Body/v_ld_prs.htm
+*LOAD-TRUENAME*
+../Body/v_ld_pns.htm
+*LOAD-VERBOSE*
+../Body/v_ld_prs.htm
+*MACROEXPAND-HOOK*
+../Body/v_mexp_h.htm
+*MODULES*
+../Body/v_module.htm
+*PACKAGE*
+../Body/v_pkg.htm
+*PRINT-ARRAY*
+../Body/v_pr_ar.htm
+*PRINT-BASE*
+../Body/v_pr_bas.htm
+*PRINT-CASE*
+../Body/v_pr_cas.htm
+*PRINT-CIRCLE*
+../Body/v_pr_cir.htm
+*PRINT-ESCAPE*
+../Body/v_pr_esc.htm
+*PRINT-GENSYM*
+../Body/v_pr_gen.htm
+*PRINT-LENGTH*
+../Body/v_pr_lev.htm
+*PRINT-LEVEL*
+../Body/v_pr_lev.htm
+*PRINT-LINES*
+../Body/v_pr_lin.htm
+*PRINT-MISER-WIDTH*
+../Body/v_pr_mis.htm
+*PRINT-PPRINT-DISPATCH*
+../Body/v_pr_ppr.htm
+*PRINT-PRETTY*
+../Body/v_pr_pre.htm
+*PRINT-RADIX*
+../Body/v_pr_bas.htm
+*PRINT-READABLY*
+../Body/v_pr_rda.htm
+*PRINT-RIGHT-MARGIN*
+../Body/v_pr_rig.htm
+*QUERY-IO*
+../Body/v_debug_.htm
+*RANDOM-STATE*
+../Body/v_rnd_st.htm
+*READ-BASE*
+../Body/v_rd_bas.htm
+*READ-DEFAULT-FLOAT-FORMAT*
+../Body/v_rd_def.htm
+*READ-EVAL*
+../Body/v_rd_eva.htm
+*READ-SUPPRESS*
+../Body/v_rd_sup.htm
+*READTABLE*
+../Body/v_rdtabl.htm
+*STANDARD-INPUT*
+../Body/v_debug_.htm
+*STANDARD-OUTPUT*
+../Body/v_debug_.htm
+*TERMINAL-IO*
+../Body/v_termin.htm
+*TRACE-OUTPUT*
+../Body/v_debug_.htm
++
+../Body/a_pl.htm
+++
+../Body/v_pl_plp.htm
++++
+../Body/v_pl_plp.htm
+-
+../Body/a__.htm
+/
+../Body/a_sl.htm
+//
+../Body/v_sl_sls.htm
+///
+../Body/v_sl_sls.htm
+/=
+../Body/f_eq_sle.htm
+1+
+../Body/f_1pl_1_.htm
+1-
+../Body/f_1pl_1_.htm
+<
+../Body/f_eq_sle.htm
+<=
+../Body/f_eq_sle.htm
+=
+../Body/f_eq_sle.htm
+>
+../Body/f_eq_sle.htm
+>=
+../Body/f_eq_sle.htm
+ABORT
+../Body/a_abort.htm
+ABS
+../Body/f_abs.htm
+ACONS
+../Body/f_acons.htm
+ACOS
+../Body/f_asin_.htm
+ACOSH
+../Body/f_sinh_.htm
+ADD-METHOD
+../Body/f_add_me.htm
+ADJOIN
+../Body/f_adjoin.htm
+ADJUST-ARRAY
+../Body/f_adjust.htm
+ADJUSTABLE-ARRAY-P
+../Body/f_adju_1.htm
+ALLOCATE-INSTANCE
+../Body/f_alloca.htm
+ALPHA-CHAR-P
+../Body/f_alpha_.htm
+ALPHANUMERICP
+../Body/f_alphan.htm
+AND
+../Body/a_and.htm
+APPEND
+../Body/f_append.htm
+APPLY
+../Body/f_apply.htm
+APROPOS
+../Body/f_apropo.htm
+APROPOS-LIST
+../Body/f_apropo.htm
+AREF
+../Body/f_aref.htm
+ARITHMETIC-ERROR
+../Body/e_arithm.htm
+ARITHMETIC-ERROR-OPERANDS
+../Body/f_arithm.htm
+ARITHMETIC-ERROR-OPERATION
+../Body/f_arithm.htm
+ARRAY
+../Body/t_array.htm
+ARRAY-DIMENSION
+../Body/f_ar_dim.htm
+ARRAY-DIMENSION-LIMIT
+../Body/v_ar_dim.htm
+ARRAY-DIMENSIONS
+../Body/f_ar_d_1.htm
+ARRAY-DISPLACEMENT
+../Body/f_ar_dis.htm
+ARRAY-ELEMENT-TYPE
+../Body/f_ar_ele.htm
+ARRAY-HAS-FILL-POINTER-P
+../Body/f_ar_has.htm
+ARRAY-IN-BOUNDS-P
+../Body/f_ar_in_.htm
+ARRAY-RANK
+../Body/f_ar_ran.htm
+ARRAY-RANK-LIMIT
+../Body/v_ar_ran.htm
+ARRAY-ROW-MAJOR-INDEX
+../Body/f_ar_row.htm
+ARRAY-TOTAL-SIZE
+../Body/f_ar_tot.htm
+ARRAY-TOTAL-SIZE-LIMIT
+../Body/v_ar_tot.htm
+ARRAYP
+../Body/f_arrayp.htm
+ASH
+../Body/f_ash.htm
+ASIN
+../Body/f_asin_.htm
+ASINH
+../Body/f_sinh_.htm
+ASSERT
+../Body/m_assert.htm
+ASSOC
+../Body/f_assocc.htm
+ASSOC-IF
+../Body/f_assocc.htm
+ASSOC-IF-NOT
+../Body/f_assocc.htm
+ATAN
+../Body/f_asin_.htm
+ATANH
+../Body/f_sinh_.htm
+ATOM
+../Body/a_atom.htm
+BASE-CHAR
+../Body/t_base_c.htm
+BASE-STRING
+../Body/t_base_s.htm
+BIGNUM
+../Body/t_bignum.htm
+BIT
+../Body/a_bit.htm
+BIT-AND
+../Body/f_bt_and.htm
+BIT-ANDC1
+../Body/f_bt_and.htm
+BIT-ANDC2
+../Body/f_bt_and.htm
+BIT-EQV
+../Body/f_bt_and.htm
+BIT-IOR
+../Body/f_bt_and.htm
+BIT-NAND
+../Body/f_bt_and.htm
+BIT-NOR
+../Body/f_bt_and.htm
+BIT-NOT
+../Body/f_bt_and.htm
+BIT-ORC1
+../Body/f_bt_and.htm
+BIT-ORC2
+../Body/f_bt_and.htm
+BIT-VECTOR
+../Body/t_bt_vec.htm
+BIT-VECTOR-P
+../Body/f_bt_vec.htm
+BIT-XOR
+../Body/f_bt_and.htm
+BLOCK
+../Body/s_block.htm
+BOOLE
+../Body/f_boole.htm
+BOOLE-1
+../Body/v_b_1_b.htm
+BOOLE-2
+../Body/v_b_1_b.htm
+BOOLE-AND
+../Body/v_b_1_b.htm
+BOOLE-ANDC1
+../Body/v_b_1_b.htm
+BOOLE-ANDC2
+../Body/v_b_1_b.htm
+BOOLE-C1
+../Body/v_b_1_b.htm
+BOOLE-C2
+../Body/v_b_1_b.htm
+BOOLE-CLR
+../Body/v_b_1_b.htm
+BOOLE-EQV
+../Body/v_b_1_b.htm
+BOOLE-IOR
+../Body/v_b_1_b.htm
+BOOLE-NAND
+../Body/v_b_1_b.htm
+BOOLE-NOR
+../Body/v_b_1_b.htm
+BOOLE-ORC1
+../Body/v_b_1_b.htm
+BOOLE-ORC2
+../Body/v_b_1_b.htm
+BOOLE-SET
+../Body/v_b_1_b.htm
+BOOLE-XOR
+../Body/v_b_1_b.htm
+BOOLEAN
+../Body/t_ban.htm
+BOTH-CASE-P
+../Body/f_upper_.htm
+BOUNDP
+../Body/f_boundp.htm
+BREAK
+../Body/f_break.htm
+BROADCAST-STREAM
+../Body/t_broadc.htm
+BROADCAST-STREAM-STREAMS
+../Body/f_broadc.htm
+BUILT-IN-CLASS
+../Body/t_built_.htm
+BUTLAST
+../Body/f_butlas.htm
+BYTE
+../Body/f_by_by.htm
+BYTE-POSITION
+../Body/f_by_by.htm
+BYTE-SIZE
+../Body/f_by_by.htm
+CAAAAR
+../Body/f_car_c.htm
+CAAADR
+../Body/f_car_c.htm
+CAAAR
+../Body/f_car_c.htm
+CAADAR
+../Body/f_car_c.htm
+CAADDR
+../Body/f_car_c.htm
+CAADR
+../Body/f_car_c.htm
+CAAR
+../Body/f_car_c.htm
+CADAAR
+../Body/f_car_c.htm
+CADADR
+../Body/f_car_c.htm
+CADAR
+../Body/f_car_c.htm
+CADDAR
+../Body/f_car_c.htm
+CADDDR
+../Body/f_car_c.htm
+CADDR
+../Body/f_car_c.htm
+CADR
+../Body/f_car_c.htm
+CALL-ARGUMENTS-LIMIT
+../Body/v_call_a.htm
+CALL-METHOD
+../Body/m_call_m.htm
+CALL-NEXT-METHOD
+../Body/f_call_n.htm
+CAR
+../Body/f_car_c.htm
+CASE
+../Body/m_case_.htm
+CATCH
+../Body/s_catch.htm
+CCASE
+../Body/m_case_.htm
+CDAAAR
+../Body/f_car_c.htm
+CDAADR
+../Body/f_car_c.htm
+CDAAR
+../Body/f_car_c.htm
+CDADAR
+../Body/f_car_c.htm
+CDADDR
+../Body/f_car_c.htm
+CDADR
+../Body/f_car_c.htm
+CDAR
+../Body/f_car_c.htm
+CDDAAR
+../Body/f_car_c.htm
+CDDADR
+../Body/f_car_c.htm
+CDDAR
+../Body/f_car_c.htm
+CDDDAR
+../Body/f_car_c.htm
+CDDDDR
+../Body/f_car_c.htm
+CDDDR
+../Body/f_car_c.htm
+CDDR
+../Body/f_car_c.htm
+CDR
+../Body/f_car_c.htm
+CEILING
+../Body/f_floorc.htm
+CELL-ERROR
+../Body/e_cell_e.htm
+CELL-ERROR-NAME
+../Body/f_cell_e.htm
+CERROR
+../Body/f_cerror.htm
+CHANGE-CLASS
+../Body/f_chg_cl.htm
+CHAR
+../Body/f_char_.htm
+CHAR-CODE
+../Body/f_char_c.htm
+CHAR-CODE-LIMIT
+../Body/v_char_c.htm
+CHAR-DOWNCASE
+../Body/f_char_u.htm
+CHAR-EQUAL
+../Body/f_chareq.htm
+CHAR-GREATERP
+../Body/f_chareq.htm
+CHAR-INT
+../Body/f_char_i.htm
+CHAR-LESSP
+../Body/f_chareq.htm
+CHAR-NAME
+../Body/f_char_n.htm
+CHAR-NOT-EQUAL
+../Body/f_chareq.htm
+CHAR-NOT-GREATERP
+../Body/f_chareq.htm
+CHAR-NOT-LESSP
+../Body/f_chareq.htm
+CHAR-UPCASE
+../Body/f_char_u.htm
+CHAR/=
+../Body/f_chareq.htm
+CHAR<
+../Body/f_chareq.htm
+CHAR<=
+../Body/f_chareq.htm
+CHAR=
+../Body/f_chareq.htm
+CHAR>
+../Body/f_chareq.htm
+CHAR>=
+../Body/f_chareq.htm
+CHARACTER
+../Body/a_ch.htm
+CHARACTERP
+../Body/f_chp.htm
+CHECK-TYPE
+../Body/m_check_.htm
+CIS
+../Body/f_cis.htm
+CLASS
+../Body/t_class.htm
+CLASS-NAME
+../Body/f_class_.htm
+CLASS-OF
+../Body/f_clas_1.htm
+CLEAR-INPUT
+../Body/f_clear_.htm
+CLEAR-OUTPUT
+../Body/f_finish.htm
+CLOSE
+../Body/f_close.htm
+CLRHASH
+../Body/f_clrhas.htm
+CODE-CHAR
+../Body/f_code_c.htm
+COERCE
+../Body/f_coerce.htm
+COMPILATION-SPEED
+../Body/d_optimi.htm
+COMPILE
+../Body/f_cmp.htm
+COMPILE-FILE
+../Body/f_cmp_fi.htm
+COMPILE-FILE-PATHNAME
+../Body/f_cmp__1.htm
+COMPILED-FUNCTION
+../Body/t_cmpd_f.htm
+COMPILED-FUNCTION-P
+../Body/f_cmpd_f.htm
+COMPILER-MACRO
+../Body/f_docume.htm
+COMPILER-MACRO-FUNCTION
+../Body/f_cmp_ma.htm
+COMPLEMENT
+../Body/f_comple.htm
+COMPLEX
+../Body/a_comple.htm
+COMPLEXP
+../Body/f_comp_3.htm
+COMPUTE-APPLICABLE-METHODS
+../Body/f_comput.htm
+COMPUTE-RESTARTS
+../Body/f_comp_1.htm
+CONCATENATE
+../Body/f_concat.htm
+CONCATENATED-STREAM
+../Body/t_concat.htm
+CONCATENATED-STREAM-STREAMS
+../Body/f_conc_1.htm
+COND
+../Body/m_cond.htm
+CONDITION
+../Body/e_cnd.htm
+CONJUGATE
+../Body/f_conjug.htm
+CONS
+../Body/a_cons.htm
+CONSP
+../Body/f_consp.htm
+CONSTANTLY
+../Body/f_cons_1.htm
+CONSTANTP
+../Body/f_consta.htm
+CONTINUE
+../Body/a_contin.htm
+CONTROL-ERROR
+../Body/e_contro.htm
+COPY-ALIST
+../Body/f_cp_ali.htm
+COPY-LIST
+../Body/f_cp_lis.htm
+COPY-PPRINT-DISPATCH
+../Body/f_cp_ppr.htm
+COPY-READTABLE
+../Body/f_cp_rdt.htm
+COPY-SEQ
+../Body/f_cp_seq.htm
+COPY-STRUCTURE
+../Body/f_cp_stu.htm
+COPY-SYMBOL
+../Body/f_cp_sym.htm
+COPY-TREE
+../Body/f_cp_tre.htm
+COS
+../Body/f_sin_c.htm
+COSH
+../Body/f_sinh_.htm
+COUNT
+../Body/f_countc.htm
+COUNT-IF
+../Body/f_countc.htm
+COUNT-IF-NOT
+../Body/f_countc.htm
+CTYPECASE
+../Body/m_tpcase.htm
+DEBUG
+../Body/d_optimi.htm
+DECF
+../Body/m_incf_.htm
+DECLAIM
+../Body/m_declai.htm
+DECLARATION
+../Body/d_declar.htm
+DECLARE
+../Body/s_declar.htm
+DECODE-FLOAT
+../Body/f_dec_fl.htm
+DECODE-UNIVERSAL-TIME
+../Body/f_dec_un.htm
+DEFCLASS
+../Body/m_defcla.htm
+DEFCONSTANT
+../Body/m_defcon.htm
+DEFGENERIC
+../Body/m_defgen.htm
+DEFINE-COMPILER-MACRO
+../Body/m_define.htm
+DEFINE-CONDITION
+../Body/m_defi_5.htm
+DEFINE-METHOD-COMBINATION
+../Body/m_defi_4.htm
+DEFINE-MODIFY-MACRO
+../Body/m_defi_2.htm
+DEFINE-SETF-EXPANDER
+../Body/m_defi_3.htm
+DEFINE-SYMBOL-MACRO
+../Body/m_defi_1.htm
+DEFMACRO
+../Body/m_defmac.htm
+DEFMETHOD
+../Body/m_defmet.htm
+DEFPACKAGE
+../Body/m_defpkg.htm
+DEFPARAMETER
+../Body/m_defpar.htm
+DEFSETF
+../Body/m_defset.htm
+DEFSTRUCT
+../Body/m_defstr.htm
+DEFTYPE
+../Body/m_deftp.htm
+DEFUN
+../Body/m_defun.htm
+DEFVAR
+../Body/m_defpar.htm
+DELETE
+../Body/f_rm_rm.htm
+DELETE-DUPLICATES
+../Body/f_rm_dup.htm
+DELETE-FILE
+../Body/f_del_fi.htm
+DELETE-IF
+../Body/f_rm_rm.htm
+DELETE-IF-NOT
+../Body/f_rm_rm.htm
+DELETE-PACKAGE
+../Body/f_del_pk.htm
+DENOMINATOR
+../Body/f_numera.htm
+DEPOSIT-FIELD
+../Body/f_deposi.htm
+DESCRIBE
+../Body/f_descri.htm
+DESCRIBE-OBJECT
+../Body/f_desc_1.htm
+DESTRUCTURING-BIND
+../Body/m_destru.htm
+DIGIT-CHAR
+../Body/f_digit_.htm
+DIGIT-CHAR-P
+../Body/f_digi_1.htm
+DIRECTORY
+../Body/f_dir.htm
+DIRECTORY-NAMESTRING
+../Body/f_namest.htm
+DISASSEMBLE
+../Body/f_disass.htm
+DIVISION-BY-ZERO
+../Body/e_divisi.htm
+DO
+../Body/m_do_do.htm
+DO*
+../Body/m_do_do.htm
+DO-ALL-SYMBOLS
+../Body/m_do_sym.htm
+DO-EXTERNAL-SYMBOLS
+../Body/m_do_sym.htm
+DO-SYMBOLS
+../Body/m_do_sym.htm
+DOCUMENTATION
+../Body/f_docume.htm
+DOLIST
+../Body/m_dolist.htm
+DOTIMES
+../Body/m_dotime.htm
+DOUBLE-FLOAT
+../Body/t_short_.htm
+DOUBLE-FLOAT-EPSILON
+../Body/v_short_.htm
+DOUBLE-FLOAT-NEGATIVE-EPSILON
+../Body/v_short_.htm
+DPB
+../Body/f_dpb.htm
+DRIBBLE
+../Body/f_dribbl.htm
+DYNAMIC-EXTENT
+../Body/d_dynami.htm
+ECASE
+../Body/m_case_.htm
+ECHO-STREAM
+../Body/t_echo_s.htm
+ECHO-STREAM-INPUT-STREAM
+../Body/f_echo_s.htm
+ECHO-STREAM-OUTPUT-STREAM
+../Body/f_echo_s.htm
+ED
+../Body/f_ed.htm
+EIGHTH
+../Body/f_firstc.htm
+ELT
+../Body/f_elt.htm
+ENCODE-UNIVERSAL-TIME
+../Body/f_encode.htm
+END-OF-FILE
+../Body/e_end_of.htm
+ENDP
+../Body/f_endp.htm
+ENOUGH-NAMESTRING
+../Body/f_namest.htm
+ENSURE-DIRECTORIES-EXIST
+../Body/f_ensu_1.htm
+ENSURE-GENERIC-FUNCTION
+../Body/f_ensure.htm
+EQ
+../Body/f_eq.htm
+EQL
+../Body/a_eql.htm
+EQUAL
+../Body/f_equal.htm
+EQUALP
+../Body/f_equalp.htm
+ERROR
+../Body/a_error.htm
+ETYPECASE
+../Body/m_tpcase.htm
+EVAL
+../Body/f_eval.htm
+EVAL-WHEN
+../Body/s_eval_w.htm
+EVENP
+../Body/f_evenpc.htm
+EVERY
+../Body/f_everyc.htm
+EXP
+../Body/f_exp_e.htm
+EXPORT
+../Body/f_export.htm
+EXPT
+../Body/f_exp_e.htm
+EXTENDED-CHAR
+../Body/t_extend.htm
+FBOUNDP
+../Body/f_fbound.htm
+FCEILING
+../Body/f_floorc.htm
+FDEFINITION
+../Body/f_fdefin.htm
+FFLOOR
+../Body/f_floorc.htm
+FIFTH
+../Body/f_firstc.htm
+FILE-AUTHOR
+../Body/f_file_a.htm
+FILE-ERROR
+../Body/e_file_e.htm
+FILE-ERROR-PATHNAME
+../Body/f_file_e.htm
+FILE-LENGTH
+../Body/f_file_l.htm
+FILE-NAMESTRING
+../Body/f_namest.htm
+FILE-POSITION
+../Body/f_file_p.htm
+FILE-STREAM
+../Body/t_file_s.htm
+FILE-STRING-LENGTH
+../Body/f_file_s.htm
+FILE-WRITE-DATE
+../Body/f_file_w.htm
+FILL
+../Body/f_fill.htm
+FILL-POINTER
+../Body/f_fill_p.htm
+FIND
+../Body/f_find_.htm
+FIND-ALL-SYMBOLS
+../Body/f_find_a.htm
+FIND-CLASS
+../Body/f_find_c.htm
+FIND-IF
+../Body/f_find_.htm
+FIND-IF-NOT
+../Body/f_find_.htm
+FIND-METHOD
+../Body/f_find_m.htm
+FIND-PACKAGE
+../Body/f_find_p.htm
+FIND-RESTART
+../Body/f_find_r.htm
+FIND-SYMBOL
+../Body/f_find_s.htm
+FINISH-OUTPUT
+../Body/f_finish.htm
+FIRST
+../Body/f_firstc.htm
+FIXNUM
+../Body/t_fixnum.htm
+FLET
+../Body/s_flet_.htm
+FLOAT
+../Body/a_float.htm
+FLOAT-DIGITS
+../Body/f_dec_fl.htm
+FLOAT-PRECISION
+../Body/f_dec_fl.htm
+FLOAT-RADIX
+../Body/f_dec_fl.htm
+FLOAT-SIGN
+../Body/f_dec_fl.htm
+FLOATING-POINT-INEXACT
+../Body/e_floa_1.htm
+FLOATING-POINT-INVALID-OPERATION
+../Body/e_floati.htm
+FLOATING-POINT-OVERFLOW
+../Body/e_floa_2.htm
+FLOATING-POINT-UNDERFLOW
+../Body/e_floa_3.htm
+FLOATP
+../Body/f_floatp.htm
+FLOOR
+../Body/f_floorc.htm
+FMAKUNBOUND
+../Body/f_fmakun.htm
+FORCE-OUTPUT
+../Body/f_finish.htm
+FORMAT
+../Body/f_format.htm
+FORMATTER
+../Body/m_format.htm
+FOURTH
+../Body/f_firstc.htm
+FRESH-LINE
+../Body/f_terpri.htm
+FROUND
+../Body/f_floorc.htm
+FTRUNCATE
+../Body/f_floorc.htm
+FTYPE
+../Body/d_ftype.htm
+FUNCALL
+../Body/f_funcal.htm
+FUNCTION
+../Body/a_fn.htm
+FUNCTION-KEYWORDS
+../Body/f_fn_kwd.htm
+FUNCTION-LAMBDA-EXPRESSION
+../Body/f_fn_lam.htm
+FUNCTIONP
+../Body/f_fnp.htm
+GCD
+../Body/f_gcd.htm
+GENERIC-FUNCTION
+../Body/t_generi.htm
+GENSYM
+../Body/f_gensym.htm
+GENTEMP
+../Body/f_gentem.htm
+GET
+../Body/f_get.htm
+GET-DECODED-TIME
+../Body/f_get_un.htm
+GET-DISPATCH-MACRO-CHARACTER
+../Body/f_set__1.htm
+GET-INTERNAL-REAL-TIME
+../Body/f_get_in.htm
+GET-INTERNAL-RUN-TIME
+../Body/f_get__1.htm
+GET-MACRO-CHARACTER
+../Body/f_set_ma.htm
+GET-OUTPUT-STREAM-STRING
+../Body/f_get_ou.htm
+GET-PROPERTIES
+../Body/f_get_pr.htm
+GET-SETF-EXPANSION
+../Body/f_get_se.htm
+GET-UNIVERSAL-TIME
+../Body/f_get_un.htm
+GETF
+../Body/f_getf.htm
+GETHASH
+../Body/f_gethas.htm
+GO
+../Body/s_go.htm
+GRAPHIC-CHAR-P
+../Body/f_graphi.htm
+HANDLER-BIND
+../Body/m_handle.htm
+HANDLER-CASE
+../Body/m_hand_1.htm
+HASH-TABLE
+../Body/t_hash_t.htm
+HASH-TABLE-COUNT
+../Body/f_hash_1.htm
+HASH-TABLE-P
+../Body/f_hash_t.htm
+HASH-TABLE-REHASH-SIZE
+../Body/f_hash_2.htm
+HASH-TABLE-REHASH-THRESHOLD
+../Body/f_hash_3.htm
+HASH-TABLE-SIZE
+../Body/f_hash_4.htm
+HASH-TABLE-TEST
+../Body/f_hash_5.htm
+HOST-NAMESTRING
+../Body/f_namest.htm
+IDENTITY
+../Body/f_identi.htm
+IF
+../Body/s_if.htm
+IGNORABLE
+../Body/d_ignore.htm
+IGNORE
+../Body/d_ignore.htm
+IGNORE-ERRORS
+../Body/m_ignore.htm
+IMAGPART
+../Body/f_realpa.htm
+IMPORT
+../Body/f_import.htm
+IN-PACKAGE
+../Body/m_in_pkg.htm
+INCF
+../Body/m_incf_.htm
+INITIALIZE-INSTANCE
+../Body/f_init_i.htm
+INLINE
+../Body/d_inline.htm
+INPUT-STREAM-P
+../Body/f_in_stm.htm
+INSPECT
+../Body/f_inspec.htm
+INTEGER
+../Body/t_intege.htm
+INTEGER-DECODE-FLOAT
+../Body/f_dec_fl.htm
+INTEGER-LENGTH
+../Body/f_intege.htm
+INTEGERP
+../Body/f_inte_1.htm
+INTERACTIVE-STREAM-P
+../Body/f_intera.htm
+INTERN
+../Body/f_intern.htm
+INTERNAL-TIME-UNITS-PER-SECOND
+../Body/v_intern.htm
+INTERSECTION
+../Body/f_isec_.htm
+INVALID-METHOD-ERROR
+../Body/f_invali.htm
+INVOKE-DEBUGGER
+../Body/f_invoke.htm
+INVOKE-RESTART
+../Body/f_invo_1.htm
+INVOKE-RESTART-INTERACTIVELY
+../Body/f_invo_2.htm
+ISQRT
+../Body/f_sqrt_.htm
+KEYWORD
+../Body/t_kwd.htm
+KEYWORDP
+../Body/f_kwdp.htm
+LABELS
+../Body/s_flet_.htm
+LAMBDA
+../Body/a_lambda.htm
+LAMBDA-LIST-KEYWORDS
+../Body/v_lambda.htm
+LAMBDA-PARAMETERS-LIMIT
+../Body/v_lamb_1.htm
+LAST
+../Body/f_last.htm
+LCM
+../Body/f_lcm.htm
+LDB
+../Body/f_ldb.htm
+LDB-TEST
+../Body/f_ldb_te.htm
+LDIFF
+../Body/f_ldiffc.htm
+LEAST-NEGATIVE-DOUBLE-FLOAT
+../Body/v_most_1.htm
+LEAST-NEGATIVE-LONG-FLOAT
+../Body/v_most_1.htm
+LEAST-NEGATIVE-NORMALIZED-DOUBLE-FLOAT
+../Body/v_most_1.htm
+LEAST-NEGATIVE-NORMALIZED-LONG-FLOAT
+../Body/v_most_1.htm
+LEAST-NEGATIVE-NORMALIZED-SHORT-FLOAT
+../Body/v_most_1.htm
+LEAST-NEGATIVE-NORMALIZED-SINGLE-FLOAT
+../Body/v_most_1.htm
+LEAST-NEGATIVE-SHORT-FLOAT
+../Body/v_most_1.htm
+LEAST-NEGATIVE-SINGLE-FLOAT
+../Body/v_most_1.htm
+LEAST-POSITIVE-DOUBLE-FLOAT
+../Body/v_most_1.htm
+LEAST-POSITIVE-LONG-FLOAT
+../Body/v_most_1.htm
+LEAST-POSITIVE-NORMALIZED-DOUBLE-FLOAT
+../Body/v_most_1.htm
+LEAST-POSITIVE-NORMALIZED-LONG-FLOAT
+../Body/v_most_1.htm
+LEAST-POSITIVE-NORMALIZED-SHORT-FLOAT
+../Body/v_most_1.htm
+LEAST-POSITIVE-NORMALIZED-SINGLE-FLOAT
+../Body/v_most_1.htm
+LEAST-POSITIVE-SHORT-FLOAT
+../Body/v_most_1.htm
+LEAST-POSITIVE-SINGLE-FLOAT
+../Body/v_most_1.htm
+LENGTH
+../Body/f_length.htm
+LET
+../Body/s_let_l.htm
+LET*
+../Body/s_let_l.htm
+LISP-IMPLEMENTATION-TYPE
+../Body/f_lisp_i.htm
+LISP-IMPLEMENTATION-VERSION
+../Body/f_lisp_i.htm
+LIST
+../Body/a_list.htm
+LIST*
+../Body/f_list_.htm
+LIST-ALL-PACKAGES
+../Body/f_list_a.htm
+LIST-LENGTH
+../Body/f_list_l.htm
+LISTEN
+../Body/f_listen.htm
+LISTP
+../Body/f_listp.htm
+LOAD
+../Body/f_load.htm
+LOAD-LOGICAL-PATHNAME-TRANSLATIONS
+../Body/f_ld_log.htm
+LOAD-TIME-VALUE
+../Body/s_ld_tim.htm
+LOCALLY
+../Body/s_locall.htm
+LOG
+../Body/f_log.htm
+LOGAND
+../Body/f_logand.htm
+LOGANDC1
+../Body/f_logand.htm
+LOGANDC2
+../Body/f_logand.htm
+LOGBITP
+../Body/f_logbtp.htm
+LOGCOUNT
+../Body/f_logcou.htm
+LOGEQV
+../Body/f_logand.htm
+LOGICAL-PATHNAME
+../Body/a_logica.htm
+LOGICAL-PATHNAME-TRANSLATIONS
+../Body/f_logica.htm
+LOGIOR
+../Body/f_logand.htm
+LOGNAND
+../Body/f_logand.htm
+LOGNOR
+../Body/f_logand.htm
+LOGNOT
+../Body/f_logand.htm
+LOGORC1
+../Body/f_logand.htm
+LOGORC2
+../Body/f_logand.htm
+LOGTEST
+../Body/f_logtes.htm
+LOGXOR
+../Body/f_logand.htm
+LONG-FLOAT
+../Body/t_short_.htm
+LONG-FLOAT-EPSILON
+../Body/v_short_.htm
+LONG-FLOAT-NEGATIVE-EPSILON
+../Body/v_short_.htm
+LONG-SITE-NAME
+../Body/f_short_.htm
+LOOP
+../Body/m_loop.htm
+LOOP-FINISH
+../Body/m_loop_f.htm
+LOWER-CASE-P
+../Body/f_upper_.htm
+MACHINE-INSTANCE
+../Body/f_mach_i.htm
+MACHINE-TYPE
+../Body/f_mach_t.htm
+MACHINE-VERSION
+../Body/f_mach_v.htm
+MACRO-FUNCTION
+../Body/f_macro_.htm
+MACROEXPAND
+../Body/f_mexp_.htm
+MACROEXPAND-1
+../Body/f_mexp_.htm
+MACROLET
+../Body/s_flet_.htm
+MAKE-ARRAY
+../Body/f_mk_ar.htm
+MAKE-BROADCAST-STREAM
+../Body/f_mk_bro.htm
+MAKE-CONCATENATED-STREAM
+../Body/f_mk_con.htm
+MAKE-CONDITION
+../Body/f_mk_cnd.htm
+MAKE-DISPATCH-MACRO-CHARACTER
+../Body/f_mk_dis.htm
+MAKE-ECHO-STREAM
+../Body/f_mk_ech.htm
+MAKE-HASH-TABLE
+../Body/f_mk_has.htm
+MAKE-INSTANCE
+../Body/f_mk_ins.htm
+MAKE-INSTANCES-OBSOLETE
+../Body/f_mk_i_1.htm
+MAKE-LIST
+../Body/f_mk_lis.htm
+MAKE-LOAD-FORM
+../Body/f_mk_ld_.htm
+MAKE-LOAD-FORM-SAVING-SLOTS
+../Body/f_mk_l_1.htm
+MAKE-METHOD
+../Body/m_call_m.htm
+MAKE-PACKAGE
+../Body/f_mk_pkg.htm
+MAKE-PATHNAME
+../Body/f_mk_pn.htm
+MAKE-RANDOM-STATE
+../Body/f_mk_rnd.htm
+MAKE-SEQUENCE
+../Body/f_mk_seq.htm
+MAKE-STRING
+../Body/f_mk_stg.htm
+MAKE-STRING-INPUT-STREAM
+../Body/f_mk_s_1.htm
+MAKE-STRING-OUTPUT-STREAM
+../Body/f_mk_s_2.htm
+MAKE-SYMBOL
+../Body/f_mk_sym.htm
+MAKE-SYNONYM-STREAM
+../Body/f_mk_syn.htm
+MAKE-TWO-WAY-STREAM
+../Body/f_mk_two.htm
+MAKUNBOUND
+../Body/f_makunb.htm
+MAP
+../Body/f_map.htm
+MAP-INTO
+../Body/f_map_in.htm
+MAPC
+../Body/f_mapc_.htm
+MAPCAN
+../Body/f_mapc_.htm
+MAPCAR
+../Body/f_mapc_.htm
+MAPCON
+../Body/f_mapc_.htm
+MAPHASH
+../Body/f_maphas.htm
+MAPL
+../Body/f_mapc_.htm
+MAPLIST
+../Body/f_mapc_.htm
+MASK-FIELD
+../Body/f_mask_f.htm
+MAX
+../Body/f_max_m.htm
+MEMBER
+../Body/a_member.htm
+MEMBER-IF
+../Body/f_mem_m.htm
+MEMBER-IF-NOT
+../Body/f_mem_m.htm
+MERGE
+../Body/f_merge.htm
+MERGE-PATHNAMES
+../Body/f_merge_.htm
+METHOD
+../Body/t_method.htm
+METHOD-COMBINATION
+../Body/a_method.htm
+METHOD-COMBINATION-ERROR
+../Body/f_meth_1.htm
+METHOD-QUALIFIERS
+../Body/f_method.htm
+MIN
+../Body/f_max_m.htm
+MINUSP
+../Body/f_minusp.htm
+MISMATCH
+../Body/f_mismat.htm
+MOD
+../Body/a_mod.htm
+MOST-NEGATIVE-DOUBLE-FLOAT
+../Body/v_most_1.htm
+MOST-NEGATIVE-FIXNUM
+../Body/v_most_p.htm
+MOST-NEGATIVE-LONG-FLOAT
+../Body/v_most_1.htm
+MOST-NEGATIVE-SHORT-FLOAT
+../Body/v_most_1.htm
+MOST-NEGATIVE-SINGLE-FLOAT
+../Body/v_most_1.htm
+MOST-POSITIVE-DOUBLE-FLOAT
+../Body/v_most_1.htm
+MOST-POSITIVE-FIXNUM
+../Body/v_most_p.htm
+MOST-POSITIVE-LONG-FLOAT
+../Body/v_most_1.htm
+MOST-POSITIVE-SHORT-FLOAT
+../Body/v_most_1.htm
+MOST-POSITIVE-SINGLE-FLOAT
+../Body/v_most_1.htm
+MUFFLE-WARNING
+../Body/a_muffle.htm
+MULTIPLE-VALUE-BIND
+../Body/m_multip.htm
+MULTIPLE-VALUE-CALL
+../Body/s_multip.htm
+MULTIPLE-VALUE-LIST
+../Body/m_mult_1.htm
+MULTIPLE-VALUE-PROG1
+../Body/s_mult_1.htm
+MULTIPLE-VALUE-SETQ
+../Body/m_mult_2.htm
+MULTIPLE-VALUES-LIMIT
+../Body/v_multip.htm
+NAME-CHAR
+../Body/f_name_c.htm
+NAMESTRING
+../Body/f_namest.htm
+NBUTLAST
+../Body/f_butlas.htm
+NCONC
+../Body/f_nconc.htm
+NEXT-METHOD-P
+../Body/f_next_m.htm
+NIL
+../Body/a_nil.htm
+NINTERSECTION
+../Body/f_isec_.htm
+NINTH
+../Body/f_firstc.htm
+NO-APPLICABLE-METHOD
+../Body/f_no_app.htm
+NO-NEXT-METHOD
+../Body/f_no_nex.htm
+NOT
+../Body/a_not.htm
+NOTANY
+../Body/f_everyc.htm
+NOTEVERY
+../Body/f_everyc.htm
+NOTINLINE
+../Body/d_inline.htm
+NRECONC
+../Body/f_revapp.htm
+NREVERSE
+../Body/f_revers.htm
+NSET-DIFFERENCE
+../Body/f_set_di.htm
+NSET-EXCLUSIVE-OR
+../Body/f_set_ex.htm
+NSTRING-CAPITALIZE
+../Body/f_stg_up.htm
+NSTRING-DOWNCASE
+../Body/f_stg_up.htm
+NSTRING-UPCASE
+../Body/f_stg_up.htm
+NSUBLIS
+../Body/f_sublis.htm
+NSUBST
+../Body/f_substc.htm
+NSUBST-IF
+../Body/f_substc.htm
+NSUBST-IF-NOT
+../Body/f_substc.htm
+NSUBSTITUTE
+../Body/f_sbs_s.htm
+NSUBSTITUTE-IF
+../Body/f_sbs_s.htm
+NSUBSTITUTE-IF-NOT
+../Body/f_sbs_s.htm
+NTH
+../Body/f_nth.htm
+NTH-VALUE
+../Body/m_nth_va.htm
+NTHCDR
+../Body/f_nthcdr.htm
+NULL
+../Body/a_null.htm
+NUMBER
+../Body/t_number.htm
+NUMBERP
+../Body/f_nump.htm
+NUMERATOR
+../Body/f_numera.htm
+NUNION
+../Body/f_unionc.htm
+ODDP
+../Body/f_evenpc.htm
+OPEN
+../Body/f_open.htm
+OPEN-STREAM-P
+../Body/f_open_s.htm
+OPTIMIZE
+../Body/d_optimi.htm
+OR
+../Body/a_or.htm
+OTHERWISE
+../Body/m_case_.htm
+OUTPUT-STREAM-P
+../Body/f_in_stm.htm
+PACKAGE
+../Body/t_pkg.htm
+PACKAGE-ERROR
+../Body/e_pkg_er.htm
+PACKAGE-ERROR-PACKAGE
+../Body/f_pkg_er.htm
+PACKAGE-NAME
+../Body/f_pkg_na.htm
+PACKAGE-NICKNAMES
+../Body/f_pkg_ni.htm
+PACKAGE-SHADOWING-SYMBOLS
+../Body/f_pkg_sh.htm
+PACKAGE-USE-LIST
+../Body/f_pkg_us.htm
+PACKAGE-USED-BY-LIST
+../Body/f_pkg__1.htm
+PACKAGEP
+../Body/f_pkgp.htm
+PAIRLIS
+../Body/f_pairli.htm
+PARSE-ERROR
+../Body/e_parse_.htm
+PARSE-INTEGER
+../Body/f_parse_.htm
+PARSE-NAMESTRING
+../Body/f_pars_1.htm
+PATHNAME
+../Body/a_pn.htm
+PATHNAME-DEVICE
+../Body/f_pn_hos.htm
+PATHNAME-DIRECTORY
+../Body/f_pn_hos.htm
+PATHNAME-HOST
+../Body/f_pn_hos.htm
+PATHNAME-MATCH-P
+../Body/f_pn_mat.htm
+PATHNAME-NAME
+../Body/f_pn_hos.htm
+PATHNAME-TYPE
+../Body/f_pn_hos.htm
+PATHNAME-VERSION
+../Body/f_pn_hos.htm
+PATHNAMEP
+../Body/f_pnp.htm
+PEEK-CHAR
+../Body/f_peek_c.htm
+PHASE
+../Body/f_phase.htm
+PI
+../Body/v_pi.htm
+PLUSP
+../Body/f_minusp.htm
+POP
+../Body/m_pop.htm
+POSITION
+../Body/f_pos_p.htm
+POSITION-IF
+../Body/f_pos_p.htm
+POSITION-IF-NOT
+../Body/f_pos_p.htm
+PPRINT
+../Body/f_wr_pr.htm
+PPRINT-DISPATCH
+../Body/f_ppr_di.htm
+PPRINT-EXIT-IF-LIST-EXHAUSTED
+../Body/m_ppr_ex.htm
+PPRINT-FILL
+../Body/f_ppr_fi.htm
+PPRINT-INDENT
+../Body/f_ppr_in.htm
+PPRINT-LINEAR
+../Body/f_ppr_fi.htm
+PPRINT-LOGICAL-BLOCK
+../Body/m_ppr_lo.htm
+PPRINT-NEWLINE
+../Body/f_ppr_nl.htm
+PPRINT-POP
+../Body/m_ppr_po.htm
+PPRINT-TAB
+../Body/f_ppr_ta.htm
+PPRINT-TABULAR
+../Body/f_ppr_fi.htm
+PRIN1
+../Body/f_wr_pr.htm
+PRIN1-TO-STRING
+../Body/f_wr_to_.htm
+PRINC
+../Body/f_wr_pr.htm
+PRINC-TO-STRING
+../Body/f_wr_to_.htm
+PRINT
+../Body/f_wr_pr.htm
+PRINT-NOT-READABLE
+../Body/e_pr_not.htm
+PRINT-NOT-READABLE-OBJECT
+../Body/f_pr_not.htm
+PRINT-OBJECT
+../Body/f_pr_obj.htm
+PRINT-UNREADABLE-OBJECT
+../Body/m_pr_unr.htm
+PROBE-FILE
+../Body/f_probe_.htm
+PROCLAIM
+../Body/f_procla.htm
+PROG
+../Body/m_prog_.htm
+PROG*
+../Body/m_prog_.htm
+PROG1
+../Body/m_prog1c.htm
+PROG2
+../Body/m_prog1c.htm
+PROGN
+../Body/s_progn.htm
+PROGRAM-ERROR
+../Body/e_progra.htm
+PROGV
+../Body/s_progv.htm
+PROVIDE
+../Body/f_provid.htm
+PSETF
+../Body/m_setf_.htm
+PSETQ
+../Body/m_psetq.htm
+PUSH
+../Body/m_push.htm
+PUSHNEW
+../Body/m_pshnew.htm
+QUOTE
+../Body/s_quote.htm
+RANDOM
+../Body/f_random.htm
+RANDOM-STATE
+../Body/t_rnd_st.htm
+RANDOM-STATE-P
+../Body/f_rnd_st.htm
+RASSOC
+../Body/f_rassoc.htm
+RASSOC-IF
+../Body/f_rassoc.htm
+RASSOC-IF-NOT
+../Body/f_rassoc.htm
+RATIO
+../Body/t_ratio.htm
+RATIONAL
+../Body/a_ration.htm
+RATIONALIZE
+../Body/f_ration.htm
+RATIONALP
+../Body/f_rati_1.htm
+READ
+../Body/f_rd_rd.htm
+READ-BYTE
+../Body/f_rd_by.htm
+READ-CHAR
+../Body/f_rd_cha.htm
+READ-CHAR-NO-HANG
+../Body/f_rd_c_1.htm
+READ-DELIMITED-LIST
+../Body/f_rd_del.htm
+READ-FROM-STRING
+../Body/f_rd_fro.htm
+READ-LINE
+../Body/f_rd_lin.htm
+READ-PRESERVING-WHITESPACE
+../Body/f_rd_rd.htm
+READ-SEQUENCE
+../Body/f_rd_seq.htm
+READER-ERROR
+../Body/e_rder_e.htm
+READTABLE
+../Body/t_rdtabl.htm
+READTABLE-CASE
+../Body/f_rdtabl.htm
+READTABLEP
+../Body/f_rdta_1.htm
+REAL
+../Body/t_real.htm
+REALP
+../Body/f_realp.htm
+REALPART
+../Body/f_realpa.htm
+REDUCE
+../Body/f_reduce.htm
+REINITIALIZE-INSTANCE
+../Body/f_reinit.htm
+REM
+../Body/f_mod_r.htm
+REMF
+../Body/m_remf.htm
+REMHASH
+../Body/f_remhas.htm
+REMOVE
+../Body/f_rm_rm.htm
+REMOVE-DUPLICATES
+../Body/f_rm_dup.htm
+REMOVE-IF
+../Body/f_rm_rm.htm
+REMOVE-IF-NOT
+../Body/f_rm_rm.htm
+REMOVE-METHOD
+../Body/f_rm_met.htm
+REMPROP
+../Body/f_rempro.htm
+RENAME-FILE
+../Body/f_rn_fil.htm
+RENAME-PACKAGE
+../Body/f_rn_pkg.htm
+REPLACE
+../Body/f_replac.htm
+REQUIRE
+../Body/f_provid.htm
+REST
+../Body/f_rest.htm
+RESTART
+../Body/t_rst.htm
+RESTART-BIND
+../Body/m_rst_bi.htm
+RESTART-CASE
+../Body/m_rst_ca.htm
+RESTART-NAME
+../Body/f_rst_na.htm
+RETURN
+../Body/m_return.htm
+RETURN-FROM
+../Body/s_ret_fr.htm
+REVAPPEND
+../Body/f_revapp.htm
+REVERSE
+../Body/f_revers.htm
+ROOM
+../Body/f_room.htm
+ROTATEF
+../Body/m_rotate.htm
+ROUND
+../Body/f_floorc.htm
+ROW-MAJOR-AREF
+../Body/f_row_ma.htm
+RPLACA
+../Body/f_rplaca.htm
+RPLACD
+../Body/f_rplaca.htm
+SAFETY
+../Body/d_optimi.htm
+SATISFIES
+../Body/t_satisf.htm
+SBIT
+../Body/f_bt_sb.htm
+SCALE-FLOAT
+../Body/f_dec_fl.htm
+SCHAR
+../Body/f_char_.htm
+SEARCH
+../Body/f_search.htm
+SECOND
+../Body/f_firstc.htm
+SEQUENCE
+../Body/t_seq.htm
+SERIOUS-CONDITION
+../Body/e_seriou.htm
+SET
+../Body/f_set.htm
+SET-DIFFERENCE
+../Body/f_set_di.htm
+SET-DISPATCH-MACRO-CHARACTER
+../Body/f_set__1.htm
+SET-EXCLUSIVE-OR
+../Body/f_set_ex.htm
+SET-MACRO-CHARACTER
+../Body/f_set_ma.htm
+SET-PPRINT-DISPATCH
+../Body/f_set_pp.htm
+SET-SYNTAX-FROM-CHAR
+../Body/f_set_sy.htm
+SETF
+../Body/a_setf.htm
+SETQ
+../Body/s_setq.htm
+SEVENTH
+../Body/f_firstc.htm
+SHADOW
+../Body/f_shadow.htm
+SHADOWING-IMPORT
+../Body/f_shdw_i.htm
+SHARED-INITIALIZE
+../Body/f_shared.htm
+SHIFTF
+../Body/m_shiftf.htm
+SHORT-FLOAT
+../Body/t_short_.htm
+SHORT-FLOAT-EPSILON
+../Body/v_short_.htm
+SHORT-FLOAT-NEGATIVE-EPSILON
+../Body/v_short_.htm
+SHORT-SITE-NAME
+../Body/f_short_.htm
+SIGNAL
+../Body/f_signal.htm
+SIGNED-BYTE
+../Body/t_sgn_by.htm
+SIGNUM
+../Body/f_signum.htm
+SIMPLE-ARRAY
+../Body/t_smp_ar.htm
+SIMPLE-BASE-STRING
+../Body/t_smp_ba.htm
+SIMPLE-BIT-VECTOR
+../Body/t_smp_bt.htm
+SIMPLE-BIT-VECTOR-P
+../Body/f_smp_bt.htm
+SIMPLE-CONDITION
+../Body/e_smp_cn.htm
+SIMPLE-CONDITION-FORMAT-ARGUMENTS
+../Body/f_smp_cn.htm
+SIMPLE-CONDITION-FORMAT-CONTROL
+../Body/f_smp_cn.htm
+SIMPLE-ERROR
+../Body/e_smp_er.htm
+SIMPLE-STRING
+../Body/t_smp_st.htm
+SIMPLE-STRING-P
+../Body/f_smp_st.htm
+SIMPLE-TYPE-ERROR
+../Body/e_smp_tp.htm
+SIMPLE-VECTOR
+../Body/t_smp_ve.htm
+SIMPLE-VECTOR-P
+../Body/f_smp_ve.htm
+SIMPLE-WARNING
+../Body/e_smp_wa.htm
+SIN
+../Body/f_sin_c.htm
+SINGLE-FLOAT
+../Body/t_short_.htm
+SINGLE-FLOAT-EPSILON
+../Body/v_short_.htm
+SINGLE-FLOAT-NEGATIVE-EPSILON
+../Body/v_short_.htm
+SINH
+../Body/f_sinh_.htm
+SIXTH
+../Body/f_firstc.htm
+SLEEP
+../Body/f_sleep.htm
+SLOT-BOUNDP
+../Body/f_slt_bo.htm
+SLOT-EXISTS-P
+../Body/f_slt_ex.htm
+SLOT-MAKUNBOUND
+../Body/f_slt_ma.htm
+SLOT-MISSING
+../Body/f_slt_mi.htm
+SLOT-UNBOUND
+../Body/f_slt_un.htm
+SLOT-VALUE
+../Body/f_slt_va.htm
+SOFTWARE-TYPE
+../Body/f_sw_tpc.htm
+SOFTWARE-VERSION
+../Body/f_sw_tpc.htm
+SOME
+../Body/f_everyc.htm
+SORT
+../Body/f_sort_.htm
+SPACE
+../Body/d_optimi.htm
+SPECIAL
+../Body/d_specia.htm
+SPECIAL-OPERATOR-P
+../Body/f_specia.htm
+SPEED
+../Body/d_optimi.htm
+SQRT
+../Body/f_sqrt_.htm
+STABLE-SORT
+../Body/f_sort_.htm
+STANDARD
+../Body/07_ffb.htm
+STANDARD-CHAR
+../Body/t_std_ch.htm
+STANDARD-CHAR-P
+../Body/f_std_ch.htm
+STANDARD-CLASS
+../Body/t_std_cl.htm
+STANDARD-GENERIC-FUNCTION
+../Body/t_std_ge.htm
+STANDARD-METHOD
+../Body/t_std_me.htm
+STANDARD-OBJECT
+../Body/t_std_ob.htm
+STEP
+../Body/m_step.htm
+STORAGE-CONDITION
+../Body/e_storag.htm
+STORE-VALUE
+../Body/a_store_.htm
+STREAM
+../Body/t_stream.htm
+STREAM-ELEMENT-TYPE
+../Body/f_stm_el.htm
+STREAM-ERROR
+../Body/e_stm_er.htm
+STREAM-ERROR-STREAM
+../Body/f_stm_er.htm
+STREAM-EXTERNAL-FORMAT
+../Body/f_stm_ex.htm
+STREAMP
+../Body/f_stmp.htm
+STRING
+../Body/a_string.htm
+STRING-CAPITALIZE
+../Body/f_stg_up.htm
+STRING-DOWNCASE
+../Body/f_stg_up.htm
+STRING-EQUAL
+../Body/f_stgeq_.htm
+STRING-GREATERP
+../Body/f_stgeq_.htm
+STRING-LEFT-TRIM
+../Body/f_stg_tr.htm
+STRING-LESSP
+../Body/f_stgeq_.htm
+STRING-NOT-EQUAL
+../Body/f_stgeq_.htm
+STRING-NOT-GREATERP
+../Body/f_stgeq_.htm
+STRING-NOT-LESSP
+../Body/f_stgeq_.htm
+STRING-RIGHT-TRIM
+../Body/f_stg_tr.htm
+STRING-STREAM
+../Body/t_stg_st.htm
+STRING-TRIM
+../Body/f_stg_tr.htm
+STRING-UPCASE
+../Body/f_stg_up.htm
+STRING/=
+../Body/f_stgeq_.htm
+STRING<
+../Body/f_stgeq_.htm
+STRING<=
+../Body/f_stgeq_.htm
+STRING=
+../Body/f_stgeq_.htm
+STRING>
+../Body/f_stgeq_.htm
+STRING>=
+../Body/f_stgeq_.htm
+STRINGP
+../Body/f_stgp.htm
+STRUCTURE
+../Body/f_docume.htm
+STRUCTURE-CLASS
+../Body/t_stu_cl.htm
+STRUCTURE-OBJECT
+../Body/t_stu_ob.htm
+STYLE-WARNING
+../Body/e_style_.htm
+SUBLIS
+../Body/f_sublis.htm
+SUBSEQ
+../Body/f_subseq.htm
+SUBSETP
+../Body/f_subset.htm
+SUBST
+../Body/f_substc.htm
+SUBST-IF
+../Body/f_substc.htm
+SUBST-IF-NOT
+../Body/f_substc.htm
+SUBSTITUTE
+../Body/f_sbs_s.htm
+SUBSTITUTE-IF
+../Body/f_sbs_s.htm
+SUBSTITUTE-IF-NOT
+../Body/f_sbs_s.htm
+SUBTYPEP
+../Body/f_subtpp.htm
+SVREF
+../Body/f_svref.htm
+SXHASH
+../Body/f_sxhash.htm
+SYMBOL
+../Body/t_symbol.htm
+SYMBOL-FUNCTION
+../Body/f_symb_1.htm
+SYMBOL-MACROLET
+../Body/s_symbol.htm
+SYMBOL-NAME
+../Body/f_symb_2.htm
+SYMBOL-PACKAGE
+../Body/f_symb_3.htm
+SYMBOL-PLIST
+../Body/f_symb_4.htm
+SYMBOL-VALUE
+../Body/f_symb_5.htm
+SYMBOLP
+../Body/f_symbol.htm
+SYNONYM-STREAM
+../Body/t_syn_st.htm
+SYNONYM-STREAM-SYMBOL
+../Body/f_syn_st.htm
+T
+../Body/a_t.htm
+TAGBODY
+../Body/s_tagbod.htm
+TAILP
+../Body/f_ldiffc.htm
+TAN
+../Body/f_sin_c.htm
+TANH
+../Body/f_sinh_.htm
+TENTH
+../Body/f_firstc.htm
+TERPRI
+../Body/f_terpri.htm
+THE
+../Body/s_the.htm
+THIRD
+../Body/f_firstc.htm
+THROW
+../Body/s_throw.htm
+TIME
+../Body/m_time.htm
+TRACE
+../Body/m_tracec.htm
+TRANSLATE-LOGICAL-PATHNAME
+../Body/f_tr_log.htm
+TRANSLATE-PATHNAME
+../Body/f_tr_pn.htm
+TREE-EQUAL
+../Body/f_tree_e.htm
+TRUENAME
+../Body/f_tn.htm
+TRUNCATE
+../Body/f_floorc.htm
+TWO-WAY-STREAM
+../Body/t_two_wa.htm
+TWO-WAY-STREAM-INPUT-STREAM
+../Body/f_two_wa.htm
+TWO-WAY-STREAM-OUTPUT-STREAM
+../Body/f_two_wa.htm
+TYPE
+../Body/a_type.htm
+TYPE-ERROR
+../Body/e_tp_err.htm
+TYPE-ERROR-DATUM
+../Body/f_tp_err.htm
+TYPE-ERROR-EXPECTED-TYPE
+../Body/f_tp_err.htm
+TYPE-OF
+../Body/f_tp_of.htm
+TYPECASE
+../Body/m_tpcase.htm
+TYPEP
+../Body/f_typep.htm
+UNBOUND-SLOT
+../Body/e_unboun.htm
+UNBOUND-SLOT-INSTANCE
+../Body/f_unboun.htm
+UNBOUND-VARIABLE
+../Body/e_unbo_1.htm
+UNDEFINED-FUNCTION
+../Body/e_undefi.htm
+UNEXPORT
+../Body/f_unexpo.htm
+UNINTERN
+../Body/f_uninte.htm
+UNION
+../Body/f_unionc.htm
+UNLESS
+../Body/m_when_.htm
+UNREAD-CHAR
+../Body/f_unrd_c.htm
+UNSIGNED-BYTE
+../Body/t_unsgn_.htm
+UNTRACE
+../Body/m_tracec.htm
+UNUSE-PACKAGE
+../Body/f_unuse_.htm
+UNWIND-PROTECT
+../Body/s_unwind.htm
+UPDATE-INSTANCE-FOR-DIFFERENT-CLASS
+../Body/f_update.htm
+UPDATE-INSTANCE-FOR-REDEFINED-CLASS
+../Body/f_upda_1.htm
+UPGRADED-ARRAY-ELEMENT-TYPE
+../Body/f_upgr_1.htm
+UPGRADED-COMPLEX-PART-TYPE
+../Body/f_upgrad.htm
+UPPER-CASE-P
+../Body/f_upper_.htm
+USE-PACKAGE
+../Body/f_use_pk.htm
+USE-VALUE
+../Body/a_use_va.htm
+USER-HOMEDIR-PATHNAME
+../Body/f_user_h.htm
+VALUES
+../Body/a_values.htm
+VALUES-LIST
+../Body/f_vals_l.htm
+VARIABLE
+../Body/f_docume.htm
+VECTOR
+../Body/a_vector.htm
+VECTOR-POP
+../Body/f_vec_po.htm
+VECTOR-PUSH
+../Body/f_vec_ps.htm
+VECTOR-PUSH-EXTEND
+../Body/f_vec_ps.htm
+VECTORP
+../Body/f_vecp.htm
+WARN
+../Body/f_warn.htm
+WARNING
+../Body/e_warnin.htm
+WHEN
+../Body/m_when_.htm
+WILD-PATHNAME-P
+../Body/f_wild_p.htm
+WITH-ACCESSORS
+../Body/m_w_acce.htm
+WITH-COMPILATION-UNIT
+../Body/m_w_comp.htm
+WITH-CONDITION-RESTARTS
+../Body/m_w_cnd_.htm
+WITH-HASH-TABLE-ITERATOR
+../Body/m_w_hash.htm
+WITH-INPUT-FROM-STRING
+../Body/m_w_in_f.htm
+WITH-OPEN-FILE
+../Body/m_w_open.htm
+WITH-OPEN-STREAM
+../Body/m_w_op_1.htm
+WITH-OUTPUT-TO-STRING
+../Body/m_w_out_.htm
+WITH-PACKAGE-ITERATOR
+../Body/m_w_pkg_.htm
+WITH-SIMPLE-RESTART
+../Body/m_w_smp_.htm
+WITH-SLOTS
+../Body/m_w_slts.htm
+WITH-STANDARD-IO-SYNTAX
+../Body/m_w_std_.htm
+WRITE
+../Body/f_wr_pr.htm
+WRITE-BYTE
+../Body/f_wr_by.htm
+WRITE-CHAR
+../Body/f_wr_cha.htm
+WRITE-LINE
+../Body/f_wr_stg.htm
+WRITE-SEQUENCE
+../Body/f_wr_seq.htm
+WRITE-STRING
+../Body/f_wr_stg.htm
+WRITE-TO-STRING
+../Body/f_wr_to_.htm
+Y-OR-N-P
+../Body/f_y_or_n.htm
+YES-OR-NO-P
+../Body/f_y_or_n.htm
+ZEROP
+../Body/f_zerop.htm
diff --git a/Lisp/moxie/Mop_Sym.txt b/Lisp/moxie/Mop_Sym.txt
new file mode 100644
index 0000000..1647166
--- /dev/null
+++ b/Lisp/moxie/Mop_Sym.txt
@@ -0,0 +1,128 @@
+SPEC2
+dictionary.html#spec2
+ADD-DEPENDENT
+dictionary.html#add-dependent
+ADD-DIRECT-METHOD
+dictionary.html#add-direct-method
+ADD-DIRECT-SUBCLASS
+dictionary.html#add-direct-subclass
+ADD-METHOD
+dictionary.html#add-method
+ALLOCATE-INSTANCE
+dictionary.html#allocate-instance
+CLASS-
+dictionary.html#class-
+COMPUTE-APPLICABLE-METHODS
+dictionary.html#compute-applicable-methods
+COMPUTE-APPLICABLE-METHODS-USING-CLASSES
+dictionary.html#compute-applicable-methods-using-classes
+COMPUTE-CLASS-PRECEDENCE-LIST
+dictionary.html#compute-class-precedence-list
+COMPUTE-DEFAULT-INITARGS
+dictionary.html#compute-default-initargs
+COMPUTE-DISCRIMINATING-FUNCTION
+dictionary.html#compute-discriminating-function
+COMPUTE-EFFECTIVE-METHOD
+dictionary.html#compute-effective-method
+COMPUTE-EFFECTIVE-SLOT-DEFINITION
+dictionary.html#compute-effective-slot-definition
+COMPUTE-SLOTS
+dictionary.html#compute-slots
+DIRECT-SLOT-DEFINITION-CLASS
+dictionary.html#direct-slot-definition-class
+EFFECTIVE-SLOT-DEFINITION-CLASS
+dictionary.html#effective-slot-definition-class
+ENSURE-CLASS
+dictionary.html#ensure-class
+ENSURE-CLASS-USING-CLASS
+dictionary.html#ensure-class-using-class
+ENSURE-GENERIC-FUNCTION
+dictionary.html#ensure-generic-function
+ENSURE-GENERIC-FUNCTION-USING-CLASS
+dictionary.html#ensure-generic-function-using-class
+EQL-SPECIALIZER-OBJECT
+dictionary.html#eql-specializer-object
+EXTRACT-LAMBDA-LIST
+dictionary.html#extract-lambda-list
+EXTRACT-SPECIALIZER-NAMES
+dictionary.html#extract-specializer-names
+FINALIZE-INHERITANCE
+dictionary.html#finalize-inheritance
+FIND-METHOD-COMBINATION
+dictionary.html#find-method-combination
+FUNCALLABLE-STANDARD-INSTANCE-ACCESS
+dictionary.html#funcallable-standard-instance-access
+GENERIC-FUNCTION-
+dictionary.html#generic-function-
+</A>
+dictionary.html#</a>
+CLASS-MO-INITARGS
+dictionary.html#class-mo-initargs
+</A>
+dictionary.html#</a>
+GF-MO-INITARGS
+dictionary.html#gf-mo-initargs
+INITIALIZATION
+dictionary.html#Initialization
+METHOD-MO-INITARGS
+dictionary.html#method-mo-initargs
+INITIALIZATION
+dictionary.html#Initialization
+SLOTD-MO-INITARGS
+dictionary.html#slotd-mo-initargs
+INTERN-EQL-SPECIALIZER
+dictionary.html#intern-eql-specializer
+MAKE-INSTANCE
+dictionary.html#make-instance
+MAKE-METHOD-LAMBDA
+dictionary.html#make-method-lambda
+MAP-DEPENDENTS
+dictionary.html#map-dependents
+METHOD-
+dictionary.html#method-
+CLASS-MO-READERS
+dictionary.html#class-mo-readers
+GF-MO-READERS
+dictionary.html#gf-mo-readers
+METHOD-MO-READERS
+dictionary.html#method-mo-readers
+SLOTD-MO-READERS
+dictionary.html#slotd-mo-readers
+READER-METHOD-CLASS
+dictionary.html#reader-method-class
+REMOVE-DEPENDENT
+dictionary.html#remove-dependent
+REMOVE-DIRECT-METHOD
+dictionary.html#remove-direct-method
+REMOVE-DIRECT-SUBCLASS
+dictionary.html#remove-direct-subclass
+REMOVE-METHOD
+dictionary.html#remove-method
+SET-FUNCALLABLE-INSTANCE-FUNCTION
+dictionary.html#set-funcallable-instance-function
+(SETF CLASS-NAME)
+dictionary.html#(setf class-name)
+(SETF GENERIC-FUNCTION-NAME)
+dictionary.html#(setf generic-function-name)
+(SETF SLOT-VALUE-USING-CLASS)
+dictionary.html#(setf slot-value-using-class)
+SLOT-BOUNDP-USING-CLASS
+dictionary.html#slot-boundp-using-class
+SLOT-DEFINITION-
+dictionary.html#slot-definition-
+SLOT-MAKUNBOUND-USING-CLASS
+dictionary.html#slot-makunbound-using-class
+SLOT-VALUE-USING-CLASS
+dictionary.html#slot-value-using-class
+SPECIALIZER-DIRECT-GENERIC-FUNCTIONS
+dictionary.html#specializer-direct-generic-functions
+SPECIALIZER-DIRECT-METHODS
+dictionary.html#specializer-direct-methods
+STANDARD-INSTANCE-ACCESS
+dictionary.html#standard-instance-access
+UPDATE-DEPENDENT
+dictionary.html#update-dependent
+VALIDATE-SUPERCLASS
+dictionary.html#validate-superclass
+WRITER-METHOD-CLASS
+dictionary.html#writer-method-class
diff --git a/Lisp/moxie/clhs-lookup.lisp b/Lisp/moxie/clhs-lookup.lisp
new file mode 100644
index 0000000..02a3a32
--- /dev/null
+++ b/Lisp/moxie/clhs-lookup.lisp
@@ -0,0 +1,148 @@
+(defpackage clhs-lookup
+ (:use :common-lisp)
+ (:export :symbol-lookup
+ :populate-table
+ :spec-lookup))
+(in-package :clhs-lookup)
+
+(defparameter *hyperspec-pathname* (translate-logical-pathname "MOXIE:RES;"))
+
+(defparameter *hyperspec-map-file* (merge-pathnames "Map_Sym.txt" *hyperspec-pathname*))
+
+(defparameter *hyperspec-root* "http://www.lispworks.com/reference/HyperSpec/")
+
+;;; AMOP.
+(defparameter *mop-map-file* (merge-pathnames "Mop_Sym.txt" *hyperspec-pathname*))
+
+(defparameter *mop-root* "http://www.alu.org/mop/")
+
+(defvar *symbol-table* (make-hash-table :test 'equal))
+
+(defvar *section-table* (make-hash-table :test 'equal))
+
+(defvar *format-table* (make-hash-table :test 'equal))
+
+(defvar *populated-p* nil)
+
+(defun add-clhs-section-to-table (&rest numbers)
+ (let ((key (format nil "~{~d~^.~}" numbers))
+ (target (concatenate 'string *hyperspec-root* (format nil "Body/~2,'0d_~(~{~36r~}~).htm" (car numbers) (mapcar #'(lambda (x) (+ x 9)) (cdr numbers))))))
+ (setf (gethash key *section-table*) target)))
+
+(defun valid-target (&rest numbers)
+ (probe-file (format nil "Body/~2,'0d_~(~{~36r~}~).htm" (car numbers) (mapcar #'(lambda (x) (+ x 9)) (cdr numbers)))))
+
+(defvar *last-warn-time* 0)
+
+(defun populate-table ()
+ (unless *populated-p*
+ ;; Hyperspec
+ (with-open-file (s *hyperspec-map-file* :if-does-not-exist nil)
+ ;; populate the table with the symbols from the Map file
+ ;; this bit is easy and portable.
+ (unless s
+ (when (> (- (get-universal-time) *last-warn-time*) 10)
+ (format *trace-output* "Warning: could not find hyperspec map file. Adjust the path at the top of clhs-lookup.lisp to get links to the HyperSpec.~%")
+ (setf *last-warn-time* (get-universal-time)))
+ (return-from populate-table nil))
+ (do ((symbol-name (read-line s nil s) (read-line s nil s))
+ (url (read-line s nil s) (read-line s nil s)))
+ ((eq url s) 'done)
+ (setf (gethash symbol-name *symbol-table*) (concatenate 'string *hyperspec-root* (subseq url 3))))
+ ;; add in section references.
+ (let ((*default-pathname-defaults* *hyperspec-pathname*))
+ ;; Yuk. I know. Fixes welcome.
+ (loop for section from 0 to 27
+ do (add-clhs-section-to-table section)
+ do (loop named s for s1 from 1 to 26
+ unless (valid-target section s1)
+ do (return-from s nil)
+ do (add-clhs-section-to-table section s1)
+ do (loop named ss for s2 from 1 to 26
+ unless (valid-target section s1 s2)
+ do (return-from ss nil)
+ do (add-clhs-section-to-table section s1 s2)
+ do (loop named sss for s3 from 1 to 26
+ unless (valid-target section s1 s2 s3)
+ do (return-from sss nil)
+ do (add-clhs-section-to-table section s1 s2 s3)
+ do (loop named ssss for s4 from 1 to 26
+ unless (valid-target section s1 s2 s3 s4)
+ do (return-from ssss nil)
+ do (add-clhs-section-to-table section s1 s2 s3 s4)
+ do (loop named sssss for s5 from 1 to 26
+ unless (valid-target section s1 s2 s3 s4 s5)
+ do (return-from sssss nil)
+ do (add-clhs-section-to-table section s1 s2 s3 s4 s5))))))))
+ ;; format directives
+ (loop for code from 32 to 127
+ do (setf (gethash (format nil "~~~A" (code-char code)) *format-table*)
+ (concatenate 'string
+ *hyperspec-root*
+ (case (code-char code)
+ ((#\c #\C) "Body/22_caa.htm")
+ ((#\%) "Body/22_cab.htm")
+ ((#\&) "Body/22_cac.htm")
+ ((#\|) "Body/22_cad.htm")
+ ((#\~) "Body/22_cae.htm")
+ ((#\r #\R) "Body/22_cba.htm")
+ ((#\d #\D) "Body/22_cbb.htm")
+ ((#\b #\B) "Body/22_cbc.htm")
+ ((#\o #\O) "Body/22_cbd.htm")
+ ((#\x #\X) "Body/22_cbe.htm")
+ ((#\f #\F) "Body/22_cca.htm")
+ ((#\e #\E) "Body/22_ccb.htm")
+ ((#\g #\G) "Body/22_ccc.htm")
+ ((#\$) "Body/22_ccd.htm")
+ ((#\a #\A) "Body/22_cda.htm")
+ ((#\s #\S) "Body/22_cdb.htm")
+ ((#\w #\W) "Body/22_cdc.htm")
+ ((#\_) "Body/22_cea.htm")
+ ;((#\<) "Body/22_ceb.htm")
+ ((#\i #\I) "Body/22_cec.htm")
+ ((#\/) "Body/22_ced.htm")
+ ((#\t #\T) "Body/22_cfa.htm")
+ ;; FIXME
+ ((#\<) "Body/22_cfb.htm")
+ ((#\>) "Body/22_cfc.htm")
+ ((#\*) "Body/22_cga.htm")
+ ((#\[) "Body/22_cgb.htm")
+ ((#\]) "Body/22_cgc.htm")
+ ((#\{) "Body/22_cgd.htm")
+ ((#\}) "Body/22_cge.htm")
+ ((#\?) "Body/22_cgf.htm")
+ ((#\() "Body/22_cha.htm")
+ ((#\)) "Body/22_chb.htm")
+ ((#\p #\P) "Body/22_chc.htm")
+ ((#\;) "Body/22_cia.htm")
+ ((#\^) "Body/22_cib.htm")
+ ((#\Newline) "Body/22_cic.htm")
+ (t "Body/22_c.htm")))))
+ ;; glossary.
+ )
+ ;; MOP
+ (with-open-file (s *mop-map-file* :if-does-not-exist nil)
+ (when s
+ (do ((symbol-name (read-line s nil s) (read-line s nil s))
+ (url (read-line s nil s) (read-line s nil s)))
+ ((eq url s) 'done)
+ (setf (gethash (concatenate 'string "MOP:" symbol-name) *symbol-table*) (concatenate 'string *mop-root* url)))))
+ (setf *populated-p* t)))
+
+(defun spec-lookup (term &key (type :all))
+ (unless *populated-p*
+ (populate-table))
+ (ecase type
+ (:all
+ (or (gethash term *symbol-table*)
+ (gethash term *section-table*)
+ (gethash term *format-table*)))
+ (:symbol
+ (gethash term *symbol-table*))
+ (:section
+ (gethash term *section-table*))
+ (:format
+ (gethash term *format-table*))))
+
+(defun symbol-lookup (term)
+ (spec-lookup term :type :symbol))
diff --git a/Lisp/moxie/compat/compat-clisp.lib b/Lisp/moxie/compat/compat-clisp.lib
new file mode 100644
index 0000000..6d4ac37
--- /dev/null
+++ b/Lisp/moxie/compat/compat-clisp.lib
@@ -0,0 +1,17 @@
+#0Y UTF-8
+(COMMON-LISP::SETQ COMMON-LISP::*PACKAGE* (SYSTEM::%FIND-PACKAGE "MOXIE"))
+(SYSTEM::C-DEFUN 'MOXIE::MAKE-RESULT-STREAM
+ (SYSTEM::LAMBDA-LIST-TO-SIGNATURE 'COMMON-LISP::NIL))
+(SYSTEM::C-DEFUN 'MOXIE::COERCE-INET-ADDRESS-DESIGNATOR
+ (SYSTEM::LAMBDA-LIST-TO-SIGNATURE '(MOXIE::HOST)))
+(SYSTEM::C-DEFUN 'MOXIE::OPEN-CONNECTION
+ (SYSTEM::LAMBDA-LIST-TO-SIGNATURE
+ '(MOXIE::HOST MOXIE::PORT COMMON-LISP::&KEY (MOXIE::BUFFERING :FULL))))
+(SYSTEM::C-DEFUN 'MOXIE::CLOSE-CONNECTION
+ (SYSTEM::LAMBDA-LIST-TO-SIGNATURE '(COMMON-LISP::STREAM)))
+(SYSTEM::C-DEFUN 'MOXIE::ADD-INPUT-HANDLER
+ (SYSTEM::LAMBDA-LIST-TO-SIGNATURE '(COMMON-LISP::STREAM MOXIE::HANDLER)))
+(SYSTEM::C-DEFUN 'MOXIE::REMOVE-INPUT-HANDLER
+ (SYSTEM::LAMBDA-LIST-TO-SIGNATURE '(MOXIE::HANDLER)))
+(SYSTEM::C-DEFUN 'MOXIE::SAVE-LISP-AND-DIE
+ (SYSTEM::LAMBDA-LIST-TO-SIGNATURE '(MOXIE::PATH)))
diff --git a/Lisp/moxie/compat/compat-clisp.lisp b/Lisp/moxie/compat/compat-clisp.lisp
new file mode 100644
index 0000000..160d193
--- /dev/null
+++ b/Lisp/moxie/compat/compat-clisp.lisp
@@ -0,0 +1,24 @@
+;;; -*- Lisp -*-
+;; $Id: compat-clisp.lisp 40 2006-01-02 03:35:07Z bjc $
+(in-package :moxie)
+
+(defun make-result-stream ()
+ (ext:make-stream 3 :direction :output))
+
+(defun coerce-inet-address-designator (host)
+ "Coerce HOST into an addess vector.")
+
+(defun open-connection (host port &key (buffering :full))
+ "Opens a connection to HOST:PORT, returning a STREAM if successful, NIL otherwise.")
+
+(defun close-connection (stream)
+ "Closes STREAM.")
+
+(defun add-input-handler (stream handler)
+ "Adds HANDLER to the input handler list on SOCKET.")
+
+(defun remove-input-handler (handler))
+
+(defun save-lisp-and-die (path)
+ (ext:saveinitmem path)
+ (ext:quit))
diff --git a/Lisp/moxie/compat/compat-openmcl.lisp b/Lisp/moxie/compat/compat-openmcl.lisp
new file mode 100644
index 0000000..6bafbd7
--- /dev/null
+++ b/Lisp/moxie/compat/compat-openmcl.lisp
@@ -0,0 +1,59 @@
+;;; -*- Lisp -*-
+;; $Id: compat-openmcl.lisp 36 2006-01-01 20:47:40Z bjc $
+(in-package :moxie)
+
+(defvar *stream-to-process* (make-hash-table))
+(defvar *stream-to-handler* (make-hash-table))
+
+(defmacro with-thread (thread &body body)
+ `(ccl:process-interrupt ,thread
+ (lambda ()
+ ,@body)))
+
+(defun make-result-stream ()
+ (ccl::make-fd-stream 3 :direction :output))
+
+(defun coerce-inet-address-designator (host)
+ "Coerce HOST into an addess vector."
+ (or (and (integerp host) host)
+ (ccl:dotted-to-ipaddr host :errorp nil)
+ (ignore-errors (ccl:lookup-hostname host))))
+
+(defun open-connection-thread (parent stream)
+ (ccl:socket-connect stream)
+ (loop
+ (ccl:process-input-wait (ccl:stream-device stream :input))
+ (let ((handler (gethash stream *stream-to-handler*)))
+ (with-thread parent
+ (funcall handler stream)))))
+
+(defun open-connection (host port &rest args)
+ "Opens a connection to HOST:PORT, returning a STREAM if successful, NIL otherwise."
+ (declare (ignore args))
+ (let ((s (ccl:make-socket :address-family :internet :type :stream :connect :active
+ :remote-host (coerce-inet-address-designator host)
+ :remote-port port)))
+ (setf (gethash s *stream-to-process*)
+ (ccl:process-run-function (format nil "Connection to ~A:~A" host port)
+ #'open-connection-thread
+ ccl:*current-process* s))
+ s))
+
+(defun close-connection (stream)
+ "Closes STREAM."
+ (ignore-errors
+ (close stream)
+ (ccl:process-kill (gethash stream *stream-to-process*))
+ (remove-input-handler stream)
+ (remhash stream *stream-to-process*)))
+
+(defun add-input-handler (stream handler)
+ "Adds HANDLER to the input handler list on STREAM."
+ (setf (gethash stream *stream-to-handler*) handler))
+
+(defun remove-input-handler (stream)
+ "Removes all handlers from STREAM."
+ (remhash stream *stream-to-handler*))
+
+(defun save-lisp-and-die (path)
+ (ccl:save-application path)) \ No newline at end of file
diff --git a/Lisp/moxie/compat/compat-sbcl.fasl b/Lisp/moxie/compat/compat-sbcl.fasl
new file mode 100644
index 0000000..d1e2b41
--- /dev/null
+++ b/Lisp/moxie/compat/compat-sbcl.fasl
Binary files differ
diff --git a/Lisp/moxie/compat/compat-sbcl.lisp b/Lisp/moxie/compat/compat-sbcl.lisp
new file mode 100644
index 0000000..bb43bc8
--- /dev/null
+++ b/Lisp/moxie/compat/compat-sbcl.lisp
@@ -0,0 +1,49 @@
+;;; -*- Lisp -*-
+;; $Id: compat-sbcl.lisp 36 2006-01-01 20:47:40Z bjc $
+(in-package :moxie)
+
+(defvar *stream-to-handler* (make-hash-table))
+(defvar *stream-to-socket* (make-hash-table))
+
+(defun make-result-stream ()
+ (sb-sys:make-fd-stream 3 :output t))
+
+(defun coerce-inet-address-designator (host)
+ "Coerce HOST into an addess vector."
+ (cond ((typep host '(vector (unsigned-byte 8) 4)) host)
+ ((some #'alpha-char-p host) (sb-bsd-sockets:host-ent-address
+ (sb-bsd-sockets:get-host-by-name host)))
+ (t (sb-bsd-sockets:make-inet-address host))))
+
+(defun open-connection (host port &key (buffering :full))
+ "Opens a connection to HOST:PORT, returning a STREAM if successful, NIL otherwise."
+ (let ((socket (make-instance 'sb-bsd-sockets:inet-socket :type :stream
+ :protocol :tcp)))
+ (sb-bsd-sockets:socket-connect socket (coerce-inet-address-designator host) port)
+ (let ((stream (sb-bsd-sockets:socket-make-stream socket
+ :input t :output t :buffering buffering)))
+ (setf (gethash stream *stream-to-socket*) socket)
+ stream)))
+
+(defun close-connection (stream)
+ "Closes STREAM."
+ (ignore-errors
+ (remove-input-handler stream)
+ (remhash stream *stream-to-socket*)
+ (close stream)))
+
+(defun add-input-handler (stream handler)
+ "Adds HANDLER to the input handler list on SOCKET."
+ (setf (gethash stream *stream-to-handler*)
+ (sb-sys:add-fd-handler (sb-bsd-sockets:socket-file-descriptor (gethash stream *stream-to-socket*))
+ :input
+ (lambda (fd)
+ (declare (ignore fd))
+ (funcall handler stream)))))
+
+(defun remove-input-handler (stream)
+ (awhen (gethash stream *stream-to-handler*)
+ (sb-sys:remove-fd-handler it)))
+
+(defun save-lisp-and-die (path)
+ (sb-ext:save-lisp-and-die path)) \ No newline at end of file
diff --git a/Lisp/moxie/default.fasl b/Lisp/moxie/default.fasl
new file mode 100644
index 0000000..3f88e09
--- /dev/null
+++ b/Lisp/moxie/default.fasl
Binary files differ
diff --git a/Lisp/moxie/default.lisp b/Lisp/moxie/default.lisp
new file mode 100644
index 0000000..a408d68
--- /dev/null
+++ b/Lisp/moxie/default.lisp
@@ -0,0 +1,63 @@
+;;; -*- Lisp -*-
+;; $Id: world.lisp 20 2005-12-27 15:21:23Z bjc $
+;;
+;; Functions that should eventually be moved to the real plug in
+;; support methodology (i.e., with nib files).
+;;
+(in-package :moxie)
+
+(defun notify-front-end-load (&rest args)
+ (declare (ignore args))
+ (send-event-to-world *world* :change-settings (world-vars *world*)))
+
+(defun notify-front-end-close (&rest args)
+ (declare (ignore args))
+ (send-event-to-world *world* :world-closed))
+
+(defun notify-front-end-connect (&rest args)
+ (declare (ignore args))
+ (set-status-buffer "Connected")
+ (send-event-to-world *world* :world-connected))
+
+(defun notify-front-end-disconnect (&rest args)
+ (declare (ignore args))
+ (set-status-buffer "Disconnected")
+ (send-event-to-world *world* :world-disconnected))
+
+(defun notify-front-end-data (line)
+ (print-to-world *world* line))
+
+(defun notify-back-end-data (line)
+ (print-to-world *world* (format nil "-> ~A~%" line)))
+
+(defun notify-back-end-settings (alist)
+ (when (world-save-path *world*)
+ (format t "DEBUG: saving new settings: ~S~%" alist)
+ (save-world-state *world*)))
+
+(add-hook 'notify-front-end-load :world-loaded-hook)
+(add-hook 'notify-front-end-close :world-closed-hook)
+(add-hook 'notify-front-end-connect :world-connected-hook)
+(add-hook 'notify-front-end-disconnect :world-disconnected-hook)
+(add-hook 'notify-front-end-data :output-from-server-hook)
+(add-hook 'notify-back-end-data :input-from-client-hook)
+(add-hook 'notify-back-end-settings :setting-changed-hook)
+
+(defun show-by-filter (key val &optional (test #'eql))
+ (map-by-filter (lambda (world)
+ (format t "Matches ~S = ~S: ~S~%" key val world))
+ key val test))
+
+(defun map-by-filter (fn key val &optional (test #'eql))
+ (map-worlds (lambda (world)
+ (when (funcall test (world-var key world) val)
+ (funcall fn world)))))
+
+(defun do-auto-connect (&rest args)
+ (declare (ignore args))
+ (setf *tmp* *world*)
+ (when (and (not (world-connected *world*)) (world-var :connect-on-open))
+ (format t "DEBUG: auto-connecting to ~A:~A~%" (world-var :hostname) (world-var :port))
+ (world-connect)))
+
+(add-hook 'do-auto-connect :world-loaded-hook) \ No newline at end of file
diff --git a/Lisp/moxie/events.fasl b/Lisp/moxie/events.fasl
new file mode 100644
index 0000000..385f796
--- /dev/null
+++ b/Lisp/moxie/events.fasl
Binary files differ
diff --git a/Lisp/moxie/events.lisp b/Lisp/moxie/events.lisp
new file mode 100644
index 0000000..88afb71
--- /dev/null
+++ b/Lisp/moxie/events.lisp
@@ -0,0 +1,100 @@
+(in-package :moxie)
+
+(defgeneric moxie-event-handler (event &rest args)
+ (:documentation "Handle EVENT (w/ ARGS)."))
+
+(defmethod moxie-event-handler ((event (eql :world-event)) &rest args)
+ (apply #'world-event args))
+
+(defmethod moxie-event-handler ((event (eql :eval)) &rest args)
+ (do* ((f args (cdr f))
+ (form (car f) (car f)))
+ ((null f))
+ (case form
+ (:r (let ((restarts (compute-restarts))
+ (num (cadr f)))
+ (if (and (integerp num)
+ (> num 0) (<= num (length restarts)))
+ (progn
+ (setf f (cdr f))
+ (invoke-restart (elt restarts (1- num))))
+ (print-restarts restarts))))
+ ((:? :h :help) (format t "~A~%" *repl-help*))
+ (t (let (values)
+ (setq - form)
+ (setq values (multiple-value-list (eval -)))
+ (setq /// // // / / values *** ** ** * * (car /))
+ (send-command :repl-result `(:values ,@values))))))
+ (send-command :repl-result `(:prompt ,(repl-prompt))))
+
+(defmethod world-event-handler ((event (eql :close-world)) &rest args)
+ (declare (ignore args))
+ (close-world))
+
+(defmethod world-event-handler ((event (eql :connect-world)) &rest args)
+ (declare (ignore args))
+ (world-connect))
+
+(defmethod world-event-handler ((event (eql :disconnect-world)) &rest args)
+ (declare (ignore args))
+ (world-disconnect))
+
+(defmethod world-event-handler ((event (eql :load-world)) &rest args)
+ (format t "world-event-handler :load-world ~S~%" args)
+ (apply #'load-world-state *world* args))
+
+(defmethod world-event-handler ((event (eql :save-world)) &rest args)
+ (apply #'save-world-state *world* args))
+
+(defmethod world-event-handler ((event (eql :setting-changed)) &rest args)
+ (let* ((form (car args))
+ (key (car form))
+ (val (cadr form))
+ (old-val (world-var key)))
+ (unless (eql old-val val)
+ (format t "DEBUG: changing setting ~S: ~S -> ~S.~%" key old-val val)
+ (setf (world-var key) val)
+ (format t "DEBUG: running hook.~%")
+ (run-hook :setting-changed-hook (list key val old-val))
+ (format t "DEBUG: hook finished.~%"))))
+
+(defmethod world-event-handler ((event (eql :input-from-client-hook)) &rest args)
+ (send-to-mux *world* (or (run-hook event (car args)) (car args))))
+
+(defmethod load-world-state ((world world) &key path &allow-other-keys)
+ (format t "load-world-state ~S ~S~%" world path)
+ (with-open-file (s (or path (world-save-path world)))
+ (awhen (aand (read s) (parse-world-version-1 it))
+ (setf (world-vars world) it)
+ (setf (world-save-path world) path)
+ (let ((*world* world))
+ (run-hook :world-loaded-hook)))))
+
+(defmethod save-world-state ((world world) &key path as-copy &allow-other-keys)
+ (with-open-file (s (or path (world-save-path world))
+ :direction :output :if-exists :supersede
+ :if-does-not-exist :create)
+ (prin1 (write-world-version-1) s))
+ (unless as-copy
+ (setf (world-save-path world) path))
+ (let ((*world* world))
+ (run-hook :world-saved-hook)))
+
+(defun parse-world-version-1 (form)
+ "Parses a world definition in the form '(:KEY value), returning an ALIST."
+ (when (evenp (length form))
+ (labels ((keyvalue-to-alist (form &optional (accumulator nil))
+ (if (null form)
+ accumulator
+ (keyvalue-to-alist (cddr form)
+ (cons (cons (car form) (cadr form)) accumulator)))))
+ (keyvalue-to-alist form))))
+
+(defun write-world-version-1 (&optional (world *world*))
+ "Writes out a FORM of '(:KEY1 value1 :KEY2 value2) from WORLD."
+ (labels ((alist-to-keyvalue (form &optional (accumulator nil))
+ (if (null form)
+ accumulator
+ (alist-to-keyvalue (cdr form)
+ (cons (caar form) (cons (cdar form) accumulator))))))
+ (alist-to-keyvalue (world-vars world)))) \ No newline at end of file
diff --git a/Lisp/moxie/hooks.lisp b/Lisp/moxie/hooks.lisp
new file mode 100644
index 0000000..49714f6
--- /dev/null
+++ b/Lisp/moxie/hooks.lisp
@@ -0,0 +1,21 @@
+;;; -*- Lisp -*-
+;; $Id: moxie.asd,v 1.1.1.1 2005/02/15 06:06:59 shmit Exp $
+#|
+Hooks:
+
+;; Sent from world handlers
+:world-opened-hook *world*
+:world-closed-hook *world*
+:input-from-client-hook line
+:output-from-server-hook line
+
+;; This can probably just be a plugin, off :output-from-server-hook
+:telnet-option-hook telnetCodes
+
+;; Controlled by the front end, ultimately.
+:start-logging-hook
+:stop-logging-hook
+
+;; XXX: IDK
+:timer-hook
+|# \ No newline at end of file
diff --git a/Lisp/moxie/moxie.asd b/Lisp/moxie/moxie.asd
new file mode 100644
index 0000000..bda1706
--- /dev/null
+++ b/Lisp/moxie/moxie.asd
@@ -0,0 +1,34 @@
+;;; -*- Lisp -*-
+;; $Id: moxie.asd 33 2006-01-01 06:41:36Z bjc $
+(defpackage moxie-system
+ (:use :cl :asdf))
+(in-package :moxie-system)
+
+(defsystem :moxie
+ :name "Moxie REPL Components."
+ :version "0.2"
+ :author "Brian Cully <shmit@kublai.com>"
+ :maintainer "Brian Cully <shmit@kublai.com>"
+ :licence "Public Domain"
+ :description "Moxie's Lisp programming interface."
+
+ :depends-on (#+sbcl sb-bsd-sockets)
+ :components ((:file "package")
+ (:module "utils"
+ :components ((:file "bjc-utils"))
+ :depends-on ("package"))
+ (:module "compat"
+ :components ((:file #+sbcl "compat-sbcl"
+ #+clisp "compat-clisp"
+ #+openmcl "compat-openmcl"
+ #-(or sbcl clisp openmcl) (error "Compiler not supported.")))
+ :depends-on ("package"))
+ (:module "main"
+ :pathname ""
+ :components ((:file "moxie")
+ (:file "world" :depends-on ("moxie"))
+ (:file "events" :depends-on ("world"))
+ (:file "repl" :depends-on ("world"))
+ (:file "default" :depends-on ("moxie")))
+ :depends-on ("package" "compat" "utils"))))
+(pushnew :moxie *features*)
diff --git a/Lisp/moxie/moxie.fasl b/Lisp/moxie/moxie.fasl
new file mode 100644
index 0000000..70ee196
--- /dev/null
+++ b/Lisp/moxie/moxie.fasl
Binary files differ
diff --git a/Lisp/moxie/moxie.lisp b/Lisp/moxie/moxie.lisp
new file mode 100644
index 0000000..c18e630
--- /dev/null
+++ b/Lisp/moxie/moxie.lisp
@@ -0,0 +1,218 @@
+;;; The lisp bootstrapping code.
+;; $Id: moxie.lisp 29 2005-12-31 22:59:17Z bjc $
+
+(in-package :moxie)
+
+(defvar *hooks* (make-hash-table)
+ "The hooks.
+See the functions add-hook and remove-hook.")
+
+(defun add-hook (sym mode)
+ "Adds the function SYM to the list MODE."
+ (setf (gethash mode *hooks*)
+ (let ((hooks (reverse (gethash mode *hooks*))))
+ (pushnew sym hooks)
+ (nreverse hooks))))
+
+(defun remove-hook (sym mode)
+ "Removes the function HOOK from the list MODE."
+ (setf (gethash mode *hooks*) (remove sym (gethash mode *hooks*))))
+
+;; We should see how many args there are, and pass that amount in. Not just the return
+;; value. But for now, this means hooks need at least one arg.
+(defun run-hook (mode &optional arg)
+ "Runs all the hooks for MODE, in order of how they were attached."
+ (let ((result nil))
+ (do ((hooks (gethash mode *hooks*) (cdr hooks)))
+ ((or (null hooks) (null (car hooks))) result)
+ (awhen (funcall (car hooks) (or result arg))
+ (setf result it)))))
+
+(defvar *keywords* (make-hash-table :test #'equal))
+
+(defun add-keyword (sym key)
+ "Adds /KEY as a keyword, calling SYM with the rest of the input string."
+ (setf (gethash (string-upcase key) *keywords*) sym))
+
+(defun remove-keyword (key)
+ "Removes /KEY as a keyword."
+ (remhash (string-upcase key) *keywords*))
+
+(defun get-keyword (string)
+ "Finds the keyword in STRING, if any."
+ (when (and (> (length string) 0) (eql #\/ (elt string 0)))
+ (let ((pos (or (position-if (lambda (c)
+ (or (eql #\Space c)
+ (eql #\Newline c)
+ (eql #\Tab c)))
+ string)
+ (length string))))
+ (values
+ (string-upcase (subseq string 1 pos))
+ (aif (and (< pos (length string))
+ (position-if-not (lambda (c)
+ (or (eql #\Space c)
+ (eql #\Newline c)
+ (eql #\Tab c)))
+ string
+ :start pos))
+ (subseq string it (length string))
+ "")))))
+
+(defun run-keyword-hook (string &rest keywords)
+ "Runs through the keyword database for the word at the beginning of STRING."
+ (multiple-value-bind (key rem) (get-keyword string)
+ (when key
+ (or (aand (gethash key *keywords*) (apply it rem keywords)) ""))))
+
+(add-hook 'run-keyword-hook :input-from-client-hook)
+
+;; Keystrokes are keywords that look like this:
+;; keystroke := :[<modifier>-]*<keycode>
+;; modifier := cmd|opt|ctrl|shift|numpad
+;; keycode := <fkey>|character
+;; fkey := f1 .. fn .. f35
+;;
+;; So, CMD-NUMPAD-8 is:
+;; :cmd-numpad-8
+;;
+;; Okay, that won't work for the long term, because :cmd-shift-numpad-8 will be
+;; evaluated differently than :shift-cmd-numpad-8.
+(defvar *keystroke-macros* (make-hash-table)
+ "The keystroke macro to symbol dispatch table.")
+
+(defun add-keystroke-macro (sym keystroke)
+ "Adds KEYSTROKE as a keystroke-macro, calling SYM on dispatch."
+ (setf (gethash keystroke *keystroke-macros*) sym)
+ (register-keystroke-macro keystroke))
+
+(defun remove-keystroke-macro (keystroke)
+ "Removes any hint of KEYSTROKE being invoked as a keystroke-macro."
+ (remhash keystroke *keystroke-macros*)
+ (unregister-keystroke-macro keystroke))
+
+(defun run-keystroke-macro-hook (keystroke)
+ "Dispatches KEYSTROKE to the appropriate hook function."
+ (awhen (gethash keystroke *keystroke-macros*)
+ (funcall it keystroke)))
+
+(add-hook 'run-keystroke-macro-hook :keystroke-macro-hook)
+
+;;
+;; Utility functions
+;;
+(defun map-variables (string vars)
+ "Returns a string made of of substituting $[0-9]+$ in STRING variables with those positions in VARS."
+ (with-output-to-string (result)
+ (let ((strlen (1- (length string))))
+ (loop for i from 0 to strlen
+ as char = (elt string i)
+ do (aif (aand (< (1+ i) strlen) (eql char #\$)
+ (position #\$ string :start (1+ i)))
+ (let ((var (parse-integer (subseq string (1+ i) it))))
+ (when var
+ (princ (elt vars (1- var)) result))
+ (setq i it))
+ (princ char result))))
+ result))
+
+(defun escape-mux-string (string)
+ "Returns a string made from STRING with substitutions for white space."
+ (with-output-to-string (result)
+ (let ((strlen (length string)))
+ (loop for i from 0 to (1- strlen)
+ as char = (elt string i)
+ do (case char
+ ((#\Space)
+ (princ "%b" result))
+ ((#\Tab)
+ (princ "%t" result))
+ ((#\Newline #\Return)
+ (princ "%r" result))
+ (t (princ char result)))))
+ result))
+
+(defun make-attributed-string (string &rest attribute-ranges)
+ (list string attribute-ranges))
+
+(defun make-attributes (&rest attributes)
+ attributes)
+
+(defun make-range (location length)
+ (list :range location length))
+
+(defun make-color (r g b)
+ (list :color r g b))
+
+(defun make-font (name size)
+ (list :font name size))
+
+(defun make-super (n)
+ (cons :super n))
+
+(defun make-underline (n)
+ (cons :underline n))
+
+(defun make-link (url)
+ (cons :link url))
+
+;;
+;; Low level commands which interface directly to Moxie.
+;;
+;; Useful stuff to add:
+;; say, for speaking text
+;; playsound/music, for sound effects
+;;
+
+(defmacro with-response (cmd-and-args &body body)
+ `(progn
+ (apply #'send-command ,@cmd-and-args)
+ (let ((response (read)))
+ ,@body)))
+
+(defun write-array-to-mux (world &rest args)
+ "Send ARGS to the output window associated with WORLD."
+ (format (world-stream world) "~S~%" args)
+ (finish-output (world-stream world)))
+
+(defun send-to-mux (world &rest args)
+ "Send ARGS to the MUX associated with WORLD."
+ (format (world-stream world) "~A~%" (car args))
+ (finish-output (world-stream world)))
+
+(defun print-to-world (world &rest args)
+ "Send ARGS to the output window associated with WORLD."
+ (apply #'send-event-to-world world :output-from-server-hook args))
+
+(defun register-keystroke-macro (keystroke)
+ "Register KEYSTROKE as a macro with Moxie."
+ (send-command :register-keystroke keystroke))
+
+(defun unregister-keystroke-macro (keystroke)
+ "Unregisters KEYSTROKE as a macro with Moxie."
+ (send-command :unregister-keystroke keystroke))
+
+(defun set-status-buffer (string &optional (world *world*))
+ "Set the status buffer of the window associated with WORLD to STRING."
+ (send-event-to-world world :set-status-buffer string))
+
+(defun clear-screen (world)
+ (send-event-to-world world :clear-screen))
+
+(defun enable-logging (world)
+ "Enable logging for WORLD."
+ (send-event-to-world world :enable-logging))
+
+(defun disable-logging (world)
+ "Disable logging for WORLD."
+ (send-event-to-world world :disable-logging))
+
+(defun send-event-to-world (world event &rest args)
+ "Send EVENT and ARGS to WORLD's result handler."
+ (apply #'send-command (world-id world) event args))
+
+(defun send-command (cmd &rest args)
+ "Send CMD and ARGS to Moxie's generic result handler."
+ (let ((*print-pretty* nil))
+ (prin1 `(,cmd ,@args) *moxie-result-stream*))
+ #-clisp (finish-output *moxie-result-stream*)) \ No newline at end of file
diff --git a/Lisp/moxie/package.fasl b/Lisp/moxie/package.fasl
new file mode 100644
index 0000000..0eaf469
--- /dev/null
+++ b/Lisp/moxie/package.fasl
Binary files differ
diff --git a/Lisp/moxie/package.lisp b/Lisp/moxie/package.lisp
new file mode 100644
index 0000000..12514b0
--- /dev/null
+++ b/Lisp/moxie/package.lisp
@@ -0,0 +1,21 @@
+(defpackage moxie
+ (:use :cl :cl-user)
+ (:export *moxie-repl-stream*
+ add-hook remove-hook run-hook
+ add-keyword remove-keyword
+ add-keystroke-macro remove-keystroke-macro
+ map-variables escape-mux-string
+
+ *world* world-var
+
+ make-attributed-string make-attributes make-range make-font
+ make-color make-super make-underline make-link
+ send-to-mux write-array-to-mux print-to-world set-status-buffer clear-screen
+ enable-logging disable-logging))
+(in-package :moxie)
+
+(defvar *moxie-result-stream* nil
+ "Where output from the TPL goes.")
+
+(defvar *world* nil
+ "The world currently calling into a plug in function.") \ No newline at end of file
diff --git a/Lisp/moxie/repl.fasl b/Lisp/moxie/repl.fasl
new file mode 100644
index 0000000..afb126a
--- /dev/null
+++ b/Lisp/moxie/repl.fasl
Binary files differ
diff --git a/Lisp/moxie/repl.lisp b/Lisp/moxie/repl.lisp
new file mode 100644
index 0000000..b5b7bb3
--- /dev/null
+++ b/Lisp/moxie/repl.lisp
@@ -0,0 +1,95 @@
+(in-package :moxie)
+
+(defvar *repl-motd*
+ "Welcome to Moxie!
+
+To get help, enter :HELP at the prompt.")
+
+(defvar *repl-help*
+ "Top level commands:
+ :R [num] Invoke restart NUM, or list restarts.
+ :HELP :H :? Display this message.")
+
+(defvar *repl-level* 0)
+
+(defun start-repl (&optional (use-result-stream t))
+ (let ((*moxie-result-stream* (or (and use-result-stream (make-result-stream))
+ *error-output*)))
+ (format t "~%~A~%" *repl-motd*)
+ (send-command :repl-result `(:prompt ,(repl-prompt)))
+ (repl)))
+
+(defun repl ()
+ "This is Moxie's top level loop. At this point, it's only here
+because we don't want the host lisp to print results or its prompt."
+ (let* ((*debugger-hook* #'repl-dbg)
+ (*repl-level* (1+ *repl-level*))
+ (lex-level *repl-level*))
+ (loop
+ (force-output)
+ (let ((form (read)))
+ (restart-case (eval form)
+ (abort ()
+ :report (lambda (stream)
+ ;; I know this looks weird, but because the
+ ;; formatter is called from the condition
+ ;; handler's environment, and because
+ ;; *repl-level* is special, at the time of
+ ;; evaluation, *repl-level* may be higher than
+ ;; lex-level.
+ (if (eql lex-level *repl-level*)
+ (format stream "Abort handling of current request.")
+ (format stream "Return to REPL level ~A."
+ lex-level)))
+ (send-command :repl-result `(:prompt ,(repl-prompt)))))))))
+
+(defun repl-dbg (condition debugger-hook)
+ "This debugger hook just sends a message to Moxie when the debugger
+has been entered, so Moxie can keep track of the prompt."
+ (declare (ignore debugger-hook))
+ (send-command :repl-dbg `(:condition ,condition)))
+
+(defmacro eval-hook (&rest forms)
+ "Ensure all FORMS are valid for evaluation before calling
+EVAL-HOOK-HELPER."
+ (let ((helped-forms (mapcar (lambda (x) `(quote ,x)) forms)))
+ `(eval-hook-helper ,@helped-forms)))
+
+(defun eval-hook-helper (&rest forms)
+ "Evaluate all FORMS, sending the results to the Moxie output
+stream. When finished processing, send the prompt."
+ (do* ((f forms (cdr f))
+ (form (car f) (car f)))
+ ((null f))
+ (case form
+ (:r (let ((restarts (compute-restarts))
+ (num (cadr f)))
+ (if (and (integerp num)
+ (> num 0) (<= num (length restarts)))
+ (progn
+ (setf f (cdr f))
+ (invoke-restart (elt restarts (1- num))))
+ (print-restarts restarts))))
+ ((:? :h :help) (format t "~A~%" *repl-help*))
+ (t (let (values)
+ (setq - form)
+ (setq values (multiple-value-list (eval -)))
+ (setq /// // // / / values *** ** ** * * (car /))
+ (send-command :repl-result `(:values ,@values))))))
+ (send-command :repl-result `(:prompt ,(repl-prompt))))
+
+(defun print-restarts (restarts)
+ (format t "Available restarts: ~%")
+ (do ((c restarts (cdr c))
+ (i 1 (1+ i)))
+ ((null c))
+ (format t " ~A ~A~%" i (car c)))
+ (format t "Invoke restarts with :R [num]~%"))
+
+(defun repl-prompt ()
+ "Compute the prompt for Moxie's REPL."
+ (format nil "~A~@[[~A]~]> "
+ (if (eql *package* (find-package :cl-user))
+ "CL-USER"
+ (package-name *package*))
+ (when (> *repl-level* 1) *repl-level*))) \ No newline at end of file
diff --git a/Lisp/moxie/repl.lisp.old b/Lisp/moxie/repl.lisp.old
new file mode 100644
index 0000000..8ae7408
--- /dev/null
+++ b/Lisp/moxie/repl.lisp.old
@@ -0,0 +1,87 @@
+(in-package :moxie)
+
+(defvar *repl-motd*
+ "Welcome to Moxie!
+
+To get help, enter :HELP at the prompt.")
+
+(defvar *repl-help*
+ "Top level commands:
+ :R [num] Invoke restart NUM, or list restarts.
+ :HELP :H :? Display this message.")
+
+(defvar *repl-level* 0)
+
+(defun start-repl (&optional (use-result-stream t))
+ (let ((*moxie-result-stream* (or (and use-result-stream (make-result-stream))
+ *error-output*)))
+ (format t "~%~A~%" *repl-motd*)
+ (send-command :repl-result `(:prompt ,(repl-prompt)))))
+
+(defmethod moxie-event-handler ((event (eql :eval)) &rest args)
+ (let* ((*debugger-hook* #'repl-dbg)
+ (*repl-level* (1+ *repl-level*))
+ (lex-level *repl-level*))
+ (dolist (form args)
+ (force-output)
+ (restart-case (eval form)
+ (abort ()
+ :report (lambda (stream)
+ ;; I know this looks weird, but because the formatter is called
+ ;; from the condition handler's environment, and because
+ ;; *repl-level* is special, at the time of evaluation,
+ ;; *repl-level* may be higher than lex-level.
+ (if (eql lex-level *repl-level*)
+ (format stream "Abort handling of current request.")
+ (format stream "Return to REPL level ~A." lex-level)))
+ (send-command :repl-result `(:prompt ,(repl-prompt))))))))
+
+(defun repl-dbg (condition debugger-hook)
+ "This debugger hook just sends a message to Moxie when the debugger has
+been entered, so Moxie can keep track of the prompt."
+ (declare (ignore debugger-hook))
+ (send-command :repl-dbg `(:condition ,condition)))
+
+(defmacro eval-hook (&rest forms)
+ "Ensure all FORMS are valid for evaluation before calling EVAL-HOOK-HELPER."
+ (let ((helped-forms (mapcar (lambda (x) `(quote ,x)) forms)))
+ `(eval-hook-helper ,@helped-forms)))
+
+(defun eval-hook-helper (&rest forms)
+ "Evaluate all FORMS, sending the results to the Moxie output stream. When finished
+processing, send the prompt."
+ (do* ((f forms (cdr f))
+ (form (car f) (car f)))
+ ((null f))
+ (case form
+ (:r (let ((restarts (compute-restarts))
+ (num (cadr f)))
+ (if (and (integerp num)
+ (> num 0) (<= num (length restarts)))
+ (progn
+ (setf f (cdr f))
+ (invoke-restart (elt restarts (1- num))))
+ (print-restarts restarts))))
+ ((:? :h :help) (format t "~A~%" *repl-help*))
+ (t (let (values)
+ (setq - form)
+ (setq values (multiple-value-list (eval -)))
+ (setq /// // // / / values *** ** ** * * (car /))
+ (send-command :repl-result `(:values ,@values))))))
+ (send-command :repl-result `(:prompt ,(repl-prompt))))
+
+(defun print-restarts (restarts)
+ (format t "Available restarts: ~%")
+ (do ((c restarts (cdr c))
+ (i 1 (1+ i)))
+ ((null c))
+ (format t " ~A ~A~%" i (car c)))
+ (format t "Invoke restarts with :R [num]~%"))
+
+(defun repl-prompt ()
+ "Compute the prompt for Moxie's REPL."
+ (format nil "~A~@[[~A]~]> "
+ (if (eql *package* (find-package :cl-user))
+ "CL-USER"
+ (package-name *package*))
+ (when (> *repl-level* 1) *repl-level*))) \ No newline at end of file
diff --git a/Lisp/moxie/utils/bjc-utils.fasl b/Lisp/moxie/utils/bjc-utils.fasl
new file mode 100644
index 0000000..9d6cb67
--- /dev/null
+++ b/Lisp/moxie/utils/bjc-utils.fasl
Binary files differ
diff --git a/Lisp/moxie/utils/bjc-utils.lisp b/Lisp/moxie/utils/bjc-utils.lisp
new file mode 100644
index 0000000..f24774b
--- /dev/null
+++ b/Lisp/moxie/utils/bjc-utils.lisp
@@ -0,0 +1,185 @@
+;;; -*- Lisp -*-
+;; $Id: bjc-utils.lisp 19 2005-12-27 01:40:27Z bjc $
+(in-package :moxie)
+
+(defmacro while (expr &body body)
+ "Evaluate BODY continously until EXPR evaluates to FALSE."
+ `(do ()
+ ((not ,expr))
+ ,@body))
+
+(defmacro acond (&rest clauses)
+ (if (null clauses)
+ nil
+ (let ((cl1 (car clauses))
+ (sym (gensym)))
+ `(let ((,sym ,(car cl1)))
+ (if ,sym
+ (let ((it ,sym))
+ ,@(cdr cl1)
+ (acond ,@(cdr clauses))))))))
+
+(defmacro aif (expr then &optional else)
+ "Anaphoric if: if EXPR is true, set IT to the result of EXPR and evaluate THEN, otherwise evaluate ELSE."
+ `(let ((it ,expr))
+ (if it
+ ,then
+ ,else)))
+
+(defmacro awhen (expr &body body)
+ "Anaphoric when: when EXPR is true, set IT to the result of EXPR and evaluate BODY."
+ `(let ((it ,expr))
+ (when it
+ ,@body)))
+
+(defmacro awhile (expr &body body)
+ "Anaphoric while: while EXPR is true, set IT to the result of EXPR and evaluate BODY."
+ `(do ((it ,expr ,expr))
+ ((not it))
+ ,@body))
+
+(defmacro aand (&rest args)
+ (cond ((null args) t)
+ ((null (cdr args)) (car args))
+ (t `(aif ,(car args) (aand ,@(cdr args))))))
+
+(defmacro aif2 (expr &optional then else)
+ "Two-value version of aif: aif EXPR's second value is TRUE, evaluate THEN, otherwise, evaluate ELSE."
+ (let ((win (gensym)))
+ `(multiple-value-bind (it ,win) ,expr
+ (if (or it ,win) ,then ,else))))
+
+(defmacro awhile2 (expr &body body)
+ "Two-value version of awhile: awhile EXPR's second value is TRUE, evaluate BODY."
+ (let ((flag (gensym)))
+ `(let ((,flag t))
+ (while ,flag
+ (aif2 ,expr
+ (progn ,@body)
+ (setq ,flag nil))))))
+
+(defmacro with-gensyms (syms &body body)
+ `(let ,(mapcar (lambda (s) `(,s (gensym))) syms)
+ ,@body))
+
+(declaim (ftype (function (function) function) memoize))
+(defun memoize (f)
+ "Return memoized version of FN."
+ (let ((cache (make-hash-table :test #'equal)))
+ (lambda (&rest args)
+ (multiple-value-bind (val win) (gethash args cache)
+ (if win
+ val
+ (setf (gethash args cache) (apply f args)))))))
+
+(declaim (ftype (function (function integer) function) memoize-with-timeout))
+(defun memoize-with-timeout (fn len)
+ "Memoize FN for LEN seconds after initial call."
+ (let ((cache (make-hash-table :test #'equal)))
+ (lambda (&rest args)
+ (multiple-value-bind (val win) (gethash args cache)
+ (if (and win (< (get-universal-time) (car val)))
+ (cdr val)
+ (cdr (setf (gethash args cache)
+ (cons (+ len (get-universal-time))
+ (apply fn args)))))))))
+
+(defmacro enumerator (list)
+ "Returns an enumerator for LIST."
+ (let ((index (gensym)))
+ `(let ((,index 0))
+ (lambda ()
+ (progn
+ (incf ,index)
+ (nth (1- ,index) ,list))))))
+
+(defun mkstr (&rest args)
+ "Creates a str from ARGS."
+ (with-output-to-string (s)
+ (dolist (a args)
+ (princ a s))))
+
+;;
+;; This macro can save and load the state of simple variables.
+;;
+;; Use:
+;; > (setq *foo* '(1 2 3)) => (1 2 3)
+;; > (def-i/o foo-w foo-r (*foo*)) => T
+;; > (foo-w #p"/tmp/foo-vars") => NIL
+;; > (makunbound '*foo*) => *FOO*
+;; > (foo-r #p"/tmp/foo-vars") => NIL
+;; > *foo* => (1 2 3)
+(defmacro def-i/o (writer-name reader-name (&rest vars))
+ (let ((file-name (gensym))
+ (var (gensym))
+ (stream (gensym)))
+ `(progn
+ (defun ,writer-name (,file-name)
+ (with-open-file (,stream ,file-name
+ :direction :output :if-exists :supersede)
+ (dolist (,var (list ,@vars))
+ (declare (special ,@vars))
+ (print ,var ,stream))))
+ (defun ,reader-name (,file-name)
+ (with-open-file (,stream ,file-name
+ :direction :input :if-does-not-exist :error)
+ (dolist (,var ',vars)
+ (set ,var (read ,stream)))))
+ t)))
+
+(defun string-has-prefix (string prefix)
+ "Returns T if STRING begins with PREFIX, NIL otherwise."
+ (let ((strlen (length string))
+ (prefixlen (length prefix)))
+ (when (<= prefixlen strlen)
+ (do ((i 0 (1+ i)))
+ ((<= prefixlen i) t)
+ (let ((s (elt string i)) (p (elt prefix i)))
+ (when (not (eql s p))
+ (return-from string-has-prefix nil)))))))
+
+(defmacro llambda (simple-lambda-list &body body)
+ (let ((num-args (gensym))
+ (args (gensym))
+ (accumulated-args (gensym))
+ (call-lambda (gensym)))
+ (labels ((lambda-length (simple-lambda-list &optional (count 0))
+ (if (or (null simple-lambda-list)
+ (member (car simple-lambda-list)
+ '(&allow-other-keys &key &rest &aux &optional)))
+ count
+ (lambda-length (cdr simple-lambda-list) (1+ count)))))
+ `(labels ((,call-lambda (,num-args ,accumulated-args)
+ (lambda (&rest ,args)
+ (if (< (length ,args) ,num-args)
+ (,call-lambda (- ,num-args (length ,args))
+ (append ,accumulated-args ,args))
+ (apply (lambda ,simple-lambda-list ,@body)
+ (append ,accumulated-args ,args))))))
+ (,call-lambda ,(lambda-length simple-lambda-list) nil)))))
+
+(defmacro $c (f &rest args)
+ (let ((a (gensym)))
+ `(lambda ($_)
+ (flet ((my-apply (sym args)
+ (cond ((functionp sym) (apply (the function sym) args))
+ ((macro-function sym)
+ (eval (funcall (macro-function sym)
+ `(,sym ,args)
+ nil)))
+ ((symbol-function sym) (apply (symbol-function sym) args))
+ (t (error "Can't curry ~A" (type-of sym))))))
+ (let ((,a (subs-var '$_ $_
+ (list ,@(if (member '$_ args)
+ args
+ (append args '($_)))))))
+ (my-apply ,f ,a))))))
+
+(defun subs-var (sym val expr &optional accum)
+ (if (null expr)
+ (nreverse accum)
+ (subs-var sym val (cdr expr)
+ (if (and (atom (car expr))
+ (eq (car expr) sym))
+ (cons val accum)
+ (cons (car expr) accum))))) \ No newline at end of file
diff --git a/Lisp/moxie/world.fasl b/Lisp/moxie/world.fasl
new file mode 100644
index 0000000..a903e04
--- /dev/null
+++ b/Lisp/moxie/world.fasl
Binary files differ
diff --git a/Lisp/moxie/world.lisp b/Lisp/moxie/world.lisp
new file mode 100644
index 0000000..af6ee65
--- /dev/null
+++ b/Lisp/moxie/world.lisp
@@ -0,0 +1,120 @@
+;;; -*- Lisp -*-
+;; $Id: world.lisp 48 2006-01-09 00:27:16Z bjc $
+(in-package :moxie)
+
+(defvar *worlds* (make-hash-table)
+ "The world environments, keyed on world id.")
+
+(let ((next-world-id 0))
+ (defclass world ()
+ ((id :initarg :id :initform (incf next-world-id)
+ :accessor world-id
+ :documentation "The world id.")
+ (vars :initarg :vars :initform nil
+ :accessor world-vars
+ :documentation "Savable settings.")
+ (save-path :initarg :save-path :initform nil
+ :accessor world-save-path
+ :documentation "File path.")
+ (stream :initarg :stream :initform nil
+ :accessor world-stream
+ :documentation "Connection to server.")
+ (connected :initarg :connected :initform nil
+ :accessor world-connected
+ :documentation "Are we currently connected?"))
+ (:documentation "All associated world information.")))
+
+(defgeneric load-world-state (world &key path &allow-other-keys)
+ (:documentation "Returns an ALIST from WORLD's disk location, or PATH (if set)."))
+
+(defgeneric save-world-state (world &key path as-copy &allow-other-keys)
+ (:documentation "Saves WORLD's state to its disk location or PATH (if set)."))
+
+(defgeneric world-event-handler (event &rest args)
+ (:documentation "Handle EVENT (w/ ARGS) for *WORLD*."))
+
+(defmethod initialize-instance ((instance world) &rest initargs)
+ (declare (ignore initargs))
+ (format t "initialize-instance world~%")
+ (add-world (call-next-method)))
+
+(defmethod world-event-handler (event &rest args)
+ "Default handler doesn't know about anything, so it logs, instead."
+ (format t "Don't know how to handle event ~S ~S from world ~S.~%"
+ event args (world-id *world*)))
+
+(defun add-world (world)
+ (setf (gethash (world-id world) *worlds*) world))
+
+(defun remove-world (world)
+ (remhash (world-id world) *worlds*))
+
+(defun map-worlds (fn)
+ (let ((result nil))
+ (maphash (lambda (k v)
+ (declare (ignore k))
+ (setf result (cons (funcall fn v) result)))
+ *worlds*)
+ (nreverse result)))
+
+(defun map-world-vars (fn &optional (world *world*))
+ (mapcar (lambda (list)
+ (funcall fn (car list) (cdr list)))
+ (world-vars world)))
+
+(defun world-var (name &optional (world *world*))
+ "Returns the value for NAME in WORLD's environment."
+ (cdr (assoc name (world-vars world))))
+
+(defun set-world-var (name value &optional (world *world*))
+ "Sets the value of NAME to VALUE in WORLD's environment."
+ (setf (world-vars world)
+ (cons (cons name value)
+ (remove-if (lambda (x)
+ (eql (car x) name))
+ (world-vars world)))))
+
+(defsetf world-var (name &optional (world '*world*)) (value)
+ `(set-world-var ,name ,value ,world))
+
+(defun close-world (&optional (world *world*))
+ "Closes WORLD."
+ (world-disconnect world)
+ (remove-world world)
+ (let ((*world* world))
+ (run-hook :world-closed-hook)))
+
+(defun world-connect (&optional (world *world*))
+ "Connects WORLD to the host and port specified."
+ (awhen (aand (world-var :hostname world) (world-var :port world)
+ (open-connection (world-var :hostname world) (world-var :port world)))
+ (add-input-handler it
+ (lambda (stream)
+ (let ((*world* world))
+ (handler-case
+ (while (listen stream)
+ (multiple-value-bind (line missing-newline-p) (read-line stream)
+ (run-hook :output-from-server-hook line)
+ (when missing-newline-p
+ (signal 'end-of-file))))
+ (end-of-file ()
+ (world-disconnect world))))))
+ (setf (world-stream world) it)
+ (setf (world-connected world) t)
+ (let ((*world* world))
+ (run-hook :world-connected-hook))))
+
+(defun world-disconnect (&optional (world *world*))
+ "Closes the connection, if opened, for WORLD."
+ (let ((*world* world))
+ (when (world-connected *world*)
+ (close-connection (world-stream *world*))
+ (setf (world-stream *world*) nil)
+ (setf (world-connected *world*) nil)
+ (run-hook :world-disconnected-hook))))
+
+(defun world-event (world-id &rest args)
+ (format t "DEBUG: world-event ~S ~S~%" world-id args)
+ (let ((*world* (or (gethash world-id *worlds*)
+ (make-instance 'world :id world-id))))
+ (apply #'world-event-handler args))) \ No newline at end of file