;;; -*- mode:lisp;package:user;base:10.;fonts:(cptfontb) -*- ;;; $Header: /ct/ctlisp/reference.l,v 1.6 85/06/21 12:33:34 bill Exp $ ;;; $Log: /ct/ctlisp/reference.l,v $ ;;;Revision 1.6 85/06/21 12:33:34 bill ;;;Changed the record_type definitions to def_record_type. ;;; ;;;Revision 1.5 84/06/21 18:14:44 jmiller ;;;Changed the printing of the DESCRIPTION... and EXAMPLE... messages slightly. ;;; ;;;Revision 1.4 84/06/08 11:50:45 penny ;;;removed the reference from the printout ;;; ;;;Revision 1.3 83/10/16 00:08:26 pozsvath ;;;Removed franz "" lossage ;;; ;;;Revision 1.2 83/08/30 00:54:02 penny ;;;global replaces of io by ct_io ;;; ;;;Revision 1.1 83/07/12 18:15:08 penny ;;;Initial revision ;;; ;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; references ;;; ;;; Penny Muncaster-Jewell 12-July-83 ;;; ;;; See last page for edit history. ;;; ;;; ;;; ;;; ;;; ;;; This file is part of a proprietary software project. Source ;;; ;;; code and documentation describing implementation details are ;;; ;;; available on a confidential, non-disclosure basis only. These ;;; ;;; materials, including this file in particular, are trade secrets ;;; ;;; of Computer * Thought Corporation. ;;; ;;; ;;; ;;; (c) Copyright 1982 and 1983, Computer * Thought Corporation. ;;; ;;; All Rights Reserved. ;;; ;;; ;;; ;;; Reference materials: ;;; ;;; Foderaro and Sklower, The FRANZ LISP Manual, September 1981. ;;; ;;; Weinreb and Moon, LISP MACHINE MANUAL, Symbolics, July 1981. ;;; ;;; Charniak et al., 1980. Artificial Intelligence Programming. ;;; ;;; Miller, 1982. The C*T Ada Tutor: Guide to the Implementation. ;;; ;;; The following code assumes familiarity with these materials. ;;; ;;; ;;; ;;; ASSUMES CT_LOAD AND SUITABLE FILEMAP ;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; Ensure presence of needed files. (eval-when (compile load eval) (ct_load 'charmac)) ;CT char set extensions. (eval-when (compile load eval) (ct_load 'aip)) ;AIP macros pkg. (eval-when (compile load eval) (ct_load 'compat)) ;Franz/LM compat pkg. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; Compiler Declarations and Global Variables -- #+franz (declare (macros t)) ;;; a reference consists of three parts and can be used to specify ;;; a reference to any document, although initially it will be used ;;; for Language Reference Manual references only. A reference has ;;; three parts the name of the document, the section or chapter ;;; and the paragraph within that section. ;;; 1) the name will be a string eg "LRM" ;;; 2) the section is a lrmsec record that consists of three atoms ;;; representing chapter,section,subsection. The last one or two ;;; may be nil to indicate not valid. ;;; 3) the paragraph is a lrmpar record that consists of two atoms ;;; representing the range of paragraphs to look at. The last ;;; atom may be nil to indicate only one paragraph is to be read. (def_record_type lrmref *lrmref* (name section paragraph)) (def_record_type lrmsec *lrmsec* (chap sec subsec)) (def_record_type lrmpar *lrmpar* (start_par finish_par)) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; Externally Call-able Functions/Macros -- (defun printref ( ref &optional (stream t)) (let ((chapno (lrmsec%chap (lrmref%section ref))) (secno (lrmsec%sec (lrmref%section ref))) (*nopoint t) (subsecno (lrmsec%subsec (lrmref%section ref))) (stpar (lrmpar%start_par (lrmref%paragraph ref))) (finpar (lrmpar%finish_par (lrmref%paragraph ref)))) (ct_format stream "LRM Section ~A~A~A~A~A, Paragraph~a ~A~A~A" chapno (cond((null secno) "")(t ".")) (cond ((null secno) "")(t secno)) (cond((null subsecno) "")(t ".")) (cond ((null subsecno) "")(t subsecno)) (cond (finpar "s") (t "")) stpar (cond ((null finpar) "")(t "-")) (cond ((null finpar) "")(t finpar))))) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; Internal Use Only Functions/Macros -- ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;