(FILECREATED "15-Jan-85 12:28:52" {PHYLUM}<BLUEBONNET>ORIGINAL>SHOWDEFS.;1 3160 changes to: (FNS PrintCondition PrintPlanStep AssignNameToStep PrintAction PrintProducer) (VARS SHOWDEFSCOMS ShowFNS) previous date: "14-Jan-85 21:49:43" {DSK}<DSK>SHOWDEFS.;1) (* Copyright (c) by NIL. All rights reserved.) (PRETTYCOMPRINT SHOWDEFSCOMS) (RPAQQ SHOWDEFSCOMS ((FNS * ShowFNS))) (RPAQQ ShowFNS (AssignNameToStep PrintAction PrintCondition PrintPlanStep PrintProducer)) (DEFINEQ (AssignNameToStep [LAMBDA (step alist) (* JG "14-Jan-85 20:59") (* * "Builds an assoc list of (step . step-name)") (CDAR (SET alist (CONS (CONS step (GENSYM 'S)) (EVAL alist]) (PrintAction [LAMBDA (action lmargin) (* JG "14-Jan-85 21:42") (* * comment) (SETQ action (COND ((type? Paragraph action) (fetch (Paragraph text) of action)) ((type? Wff action) (ReadableWff action)) (action))) [if (EQ (CAR action) '=) then (SETQ action (LIST (CADR action) '← (CADDR action] (printout T .TAB0 lmargin " -> " # (PRINTDEF action (IPLUS lmargin 4) NIL NIL T]) (PrintCondition [LAMBDA (cond lmargin) (* JG "15-Jan-85 11:00") (* * comment) (TAB lmargin 0 T) (PRINTDEF (ReadableWff cond) lmargin NIL NIL NIL T]) (PrintPlanStep [LAMBDA (step stepnames) (* JG "15-Jan-85 11:15") (* * "Prints a plan step in human-readable format") (PROG ((stepname (AssignNameToStep step stepnames)) (lmargin 4)) (TERPRI) (TERPRI) (PRINT stepname T) [for (ke cond prod assumpt) in (fetch entries of (fetch kernel of step)) do (if ke then (SETQ cond (fetch (KernelEntry wff) of ke)) (SETQ prod (fetch producer of ke)) (SETQ assumpt (fetch assumption of ke)) (TERPRI T) (if cond then (PrintCondition cond lmargin) (if prod then (PrintProducer prod 40 stepnames)) (if assumpt then (PrintAction assumpt 50] (if (fetch action of step) then (PrintCondition T lmargin) else (PrintCondition '>>UserAction<< lmargin)) (for (as act) in (fetch assertions of step) do (SETQ act (fetch (KernelEntry wff) of as)) (if act then (PrintAction act 50]) (PrintProducer [LAMBDA (planstep lmargin alist) (* JG "14-Jan-85 20:50") (* * comment) (PROG [(name (OR (CDR (FASSOC planstep (EVAL alist))) (AssignNameToStep planstep alist] (printout T .TAB0 lmargin " [" name "] "]) ) (DECLARE: DONTCOPY (FILEMAP (NIL (506 3138 (AssignNameToStep 516 . 790) (PrintAction 792 . 1340) (PrintCondition 1342 . 1580) (PrintPlanStep 1582 . 2815) (PrintProducer 2817 . 3136))))) STOP