diff options
-rw-r--r-- | Lisp/name-conversion.lisp | 2 | ||||
-rw-r--r-- | Lisp/type-handling.lisp | 10 |
2 files changed, 9 insertions, 3 deletions
diff --git a/Lisp/name-conversion.lisp b/Lisp/name-conversion.lisp index bec232b..eb46ee4 100644 --- a/Lisp/name-conversion.lisp +++ b/Lisp/name-conversion.lisp @@ -199,4 +199,4 @@ (defun name-hyphenated->nerd-caps (string) - (remove #\- (string-capitalise-lower-case string))) + (remove #\- (string-capitalise-lower-case string)))
\ No newline at end of file diff --git a/Lisp/type-handling.lisp b/Lisp/type-handling.lisp index 45aaf22..dfb84e7 100644 --- a/Lisp/type-handling.lisp +++ b/Lisp/type-handling.lisp @@ -230,6 +230,12 @@ Returns: (VALUES typespec byte-position string-position)" (values typespec nil string-position)))) +(defun typespec (typespec-designator) + (etypecase typespec-designator + (symbol (list typespec-designator ())) + (list typespec-designator))) + + (defun print-typespec-to-string (typespec) (with-output-to-string (out) (print-typespec typespec out))) @@ -238,7 +244,7 @@ Returns: (VALUES typespec byte-position string-position)" (defun print-typespec (typespec &optional (stream *standard-output*)) "Convert a TYPESPEC into a typestring and write the result to a STREAM." (destructuring-bind (type-name modifiers &rest rest) - typespec + (typespec typespec) (dolist (modifier modifiers) (format stream "~A" (case modifier (const #\r) @@ -299,4 +305,4 @@ Returns: (VALUES typespec byte-position string-position)" (defun typespec-primary-type (typespec) - (car typespec)) + (car (typespec typespec))) |