/[slime]/slime/hyperspec.el
ViewVC logotype

Diff of /slime/hyperspec.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.15 by heller, Mon Mar 9 11:06:38 2009 UTC revision 1.16 by trittweiler, Sun Jan 31 19:07:54 2010 UTC
# Line 1257  If you copy the HyperSpec to another loc Line 1257  If you copy the HyperSpec to another loc
1257  (eval-when (load eval)  (eval-when (load eval)
1258    (defalias 'hyperspec-lookup-format 'common-lisp-hyperspec-format))    (defalias 'hyperspec-lookup-format 'common-lisp-hyperspec-format))
1259    
1260    ;;; Previously there were entries for "C" and "C: Character",
1261    ;;; which unpleasingly crowded the completion buffer, so I made
1262    ;;; it show one entry ("C - Character") only.
1263    ;;;
1264    ;;; 20100131 Tobias C Rittweiler
1265    
1266    (defun intern-clhs-format-directive (char section &optional summary)
1267      (let* ((designator (if summary (format "%s - %s" char summary) char))
1268             (symbol (intern designator common-lisp-hyperspec-format-characters)))
1269        (if (boundp symbol)
1270            (pushnew section (symbol-value symbol) :test 'equal)
1271            (set symbol (list section)))))
1272    
1273  (mapcar (lambda (entry)  (mapcar (lambda (entry)
1274            (let ((symbol (intern (car entry)            (destructuring-bind (char section &optional summary) entry
1275                                  common-lisp-hyperspec-format-characters)))              (intern-clhs-format-directive char section summary)
1276              (if (boundp symbol)              (when (and (= 1 (length char))
1277                  (pushnew (cadr entry) (symbol-value symbol) :test 'equal)                         (not (string-equal char (upcase char))))
1278                  (set symbol (cdr entry))))                (intern-clhs-format-directive (upcase char) section summary))))
1279            (when (and (= 1 (length (car entry)))          '(("c" (22 3 1 1) "Character")
1280                       (not (string-equal (car entry) (upcase (car entry)))))            ("%" (22 3 1 2) "Newline")
1281              (let ((symbol (intern (upcase (car entry))            ("&" (22 3 1 3) "Fresh-line")
1282                                    common-lisp-hyperspec-format-characters)))            ("|" (22 3 1 4) "Page")
1283                (if (boundp symbol)            ("~" (22 3 1 5) "Tilde")
1284                    (pushnew (cadr entry) (symbol-value symbol) :test 'equal)            ("r" (22 3 2 1) "Radix")
1285                    (set symbol (cdr entry))))))            ("d" (22 3 2 2) "Decimal")
1286          '(("c" (22 3 1 1)) ("C: Character" (22 3 1 1))            ("b" (22 3 2 3) "Binary")
1287            ("%" (22 3 1 2)) ("Percent: Newline" (22 3 1 2))            ("o" (22 3 2 4) "Octal")
1288            ("&" (22 3 1 3)) ("Ampersand: Fresh-line" (22 3 1 3))            ("x" (22 3 2 5) "Hexadecimal")
1289            ("|" (22 3 1 4)) ("Vertical-Bar: Page" (22 3 1 4))            ("f" (22 3 3 1) "Fixed-Format Floating-Point")
1290            ("~" (22 3 1 5)) ("Tilde: Tilde" (22 3 1 5))            ("e" (22 3 3 2) "Exponential Floating-Point")
1291            ("r" (22 3 2 1)) ("R: Radix" (22 3 2 1))            ("g" (22 3 3 3) "General Floating-Point")
1292            ("d" (22 3 2 2)) ("D: Decimal" (22 3 2-2))            ("$" (22 3 3 4) "Monetary Floating-Point")
1293            ("b" (22 3 2 3)) ("B: Binary" (22 3 2 3))            ("a" (22 3 4 1) "Aesthetic")
1294            ("o" (22 3 2 4)) ("O: Octal" (22 3 2 4))            ("s" (22 3 4 2) "Standard")
1295            ("x" (22 3 2 5)) ("X: Hexadecimal" (22 3 2 5))            ("w" (22 3 4 3) "Write")
1296            ("f" (22 3 3 1)) ("F: Fixed-Format Floating-Point" (22 3 3 1))            ("_" (22 3 5 1) "Conditional Newline")
1297            ("e" (22 3 3 2)) ("E: Exponential Floating-Point" (22 3 3 2))            ("<" (22 3 5 2) "Logical Block")
1298            ("g" (22 3 3 3)) ("G: General Floating-Point" (22 3 3 3))            ("i" (22 3 5 3) "Indent")
1299            ("$" (22 3 3 4)) ("Dollarsign: Monetary Floating-Point" (22 3 3 4))            ("/" (22 3 5 4) "Call Function")
1300            ("a" (22 3 4 1)) ("A: Aesthetic" (22 3 4 1))            ("t" (22 3 6 1) "Tabulate")
1301            ("s" (22 3 4 2)) ("S: Standard" (22 3 4 2))            ("<" (22 3 6 2) "Justification")
1302            ("w" (22 3 4 3)) ("W: Write" (22 3 4 3))            (">" (22 3 6 3) "End of Justification")
1303            ("_" (22 3 5 1)) ("Underscore: Conditional Newline" (22 3 5 1))            ("*" (22 3 7 1) "Go-To")
1304            ("<" (22 3 5 2)) ("Less-Than-Sign: Logical Block" (22 3 5 2))            ("[" (22 3 7 2) "Conditional Expression")
1305            ("i" (22 3 5 3)) ("I: Indent" (22 3 5 3))            ("]" (22 3 7 3) "End of Conditional Expression")
1306            ("/" (22 3 5 4)) ("Slash: Call Function" (22 3 5 4))            ("{" (22 3 7 4) "Iteration")
1307            ("t" (22 3 6 1)) ("T: Tabulate" (22 3 6 1))            ("}" (22 3 7 5) "End of Iteration")
1308            ("<" (22 3 6 2)) ("Less-Than-Sign: Justification" (22 3 6 2))            ("?" (22 3 7 6) "Recursive Processing")
1309            (">" (22 3 6 3)) ("Greater-Than-Sign: End of Justification" (22 3 6 3))            ("(" (22 3 8 1) "Case Conversion")
1310            ("*" (22 3 7 1)) ("Asterisk: Go-To" (22 3 7 1))            (")" (22 3 8 2) "End of Case Conversion")
1311            ("[" (22 3 7 2)) ("Left-Bracket: Conditional Expression" (22 3 7 2))            ("p" (22 3 8 3) "Plural")
1312            ("]" (22 3 7 3)) ("Right-Bracket: End of Conditional Expression" (22 3 7 3))            (";" (22 3 9 1) "Clause Separator")
1313            ("{" (22 3 7 4)) ("Left-Brace: Iteration" (22 3 7 4))            ("^" (22 3 9 2) "Escape Upward")
           ("}" (22 3 7 5)) ("Right-Brace: End of Iteration" (22 3 7 5))  
           ("?" (22 3 7 6)) ("Question-Mark: Recursive Processing" (22 3 7 6))  
           ("(" (22 3 8 1)) ("Left-Paren: Case Conversion" (22 3 8 1))  
           (")" (22 3 8 2)) ("Right-Paren: End of Case Conversion" (22 3 8 2))  
           ("p" (22 3 8 3)) ("P: Plural" (22 3 8-3))  
           (";" (22 3 9 1)) ("Semicolon: Clause Separator" (22 3 9 1))  
           ("^" (22 3 9 2)) ("Circumflex: Escape Upward" (22 3 9 2))  
1314            ("Newline: Ignored Newline" (22 3 9 3))            ("Newline: Ignored Newline" (22 3 9 3))
1315            ("Nesting of FORMAT Operations" (22 3 10 1))            ("Nesting of FORMAT Operations" (22 3 10 1))
1316            ("Missing and Additional FORMAT Arguments" (22 3 10 2))            ("Missing and Additional FORMAT Arguments" (22 3 10 2))

Legend:
Removed from v.1.15  
changed lines
  Added in v.1.16

  ViewVC Help
Powered by ViewVC 1.1.5