Commits

llibra committed 1cf1d47

Made optimize declarations customizable.

Comments (0)

Files changed (3)

 (defun decode (string &key (test (load-time-value (constantly t)))
                            (www-form nil)
                            (encoding *default-character-encoding*))
-  (declare (optimize speed (debug 0) (safety 0))
+  (declare #.*optimize-qualities*
            (type simple-string string)
            (type (function (octet) boolean) test))
   (labels ((->octet (c1 c2 pos)
 (defun encode (string &key (test #'unreservedp)
                            (www-form nil)
                            (encoding *default-character-encoding*))
-  (declare (optimize speed (debug 0) (safety 0))
+  (declare #.*optimize-qualities*
            (type (function (octet) boolean) test))
   (do* ((octets (string-to-octets string :encoding encoding))
         (length (length octets))
 (in-package :percent)
 
+(defvar *optimize-qualities*
+  '(optimize speed (debug 0) (safety 0) (space 0) (compilation-speed 0)))
+
 (defvar *default-character-encoding* :utf-8)