fork download
  1. (format t "~A ~A~%"
  2. (lisp-implementation-type)
  3. (lisp-implementation-version))
  4.  
  5. (format t "~a " 'this)
  6. (setf (readtable-case *readtable*) :invert)
  7. (format t "~a ~a~%" 'is 'aWeSoMe)
  8.  
  9. (let ((*readtable* (copy-readtable nil)))
  10. (format t "READTABLE-CASE Input Symbol-name~
  11. ~%-----------------------------------~
  12. ~%")
  13. (dolist (readtable-case '(:upcase :downcase :preserve :invert))
  14. (setf (readtable-case *readtable*) readtable-case)
  15. (dolist (input '("ZEBRA" "Zebra" "zebra"))
  16. (format t ":~A~16T~A~24T~A~%"
  17. (string-upcase readtable-case)
  18. input
  19. (symbol-name (read-from-string input))))))
Success #stdin #stdout 0.01s 10720KB
stdin
Standard input is empty
stdout
CLISP 2.49 (2010-07-07) (built on brahms.debian.org [206.12.19.115])
THIS is aWeSoMe
READTABLE-CASE  Input   Symbol-name
-----------------------------------
:UPCASE         ZEBRA   ZEBRA
:UPCASE         Zebra   ZEBRA
:UPCASE         zebra   ZEBRA
:DOWNCASE       ZEBRA   zebra
:DOWNCASE       Zebra   zebra
:DOWNCASE       zebra   zebra
:PRESERVE       ZEBRA   ZEBRA
:PRESERVE       Zebra   Zebra
:PRESERVE       zebra   zebra
:INVERT         ZEBRA   zebra
:INVERT         Zebra   Zebra
:INVERT         zebra   ZEBRA