X-Git-Url: https://git.distorted.org.uk/~mdw/zone/blobdiff_plain/aee08db8b5328dc1bc2608b89a54ca6a10b50690..63b00b21ca8bd03fa839195a760243e588ac94cc:/net.lisp?ds=sidebyside diff --git a/net.lisp b/net.lisp index aa7e395..7996827 100644 --- a/net.lisp +++ b/net.lisp @@ -269,8 +269,10 @@ (:documentation "Transform the address IP into a numeric textual form.")) (defmethod print-object ((addr ipaddr) stream) - (print-unreadable-object (addr stream :type t) - (write-string (ipaddr-string addr) stream))) + (if *print-escape* + (print-unreadable-object (addr stream :type t) + (write-string (ipaddr-string addr) stream)) + (write-string (ipaddr-string addr) stream))) (export 'ipaddrp) (defun ipaddrp (ip) @@ -388,8 +390,10 @@ (ipaddr-string (make-instance (class-of net) :addr mask)))))) (defmethod print-object ((ipn ipnet) stream) - (print-unreadable-object (ipn stream :type t) - (write-string (ipnet-string ipn) stream))) + (if *print-escape* + (print-unreadable-object (ipn stream :type t) + (write-string (ipnet-string ipn) stream)) + (write-string (ipnet-string ipn) stream))) (defun parse-subnet (class width max str &key (start 0) (end nil) (slashp t)) "Parse a subnet description from (a substring of) STR.