r5341: *** empty log message ***
authorKevin M. Rosenberg <kevin@rosenberg.net>
Sun, 20 Jul 2003 16:25:21 +0000 (16:25 +0000)
committerKevin M. Rosenberg <kevin@rosenberg.net>
Sun, 20 Jul 2003 16:25:21 +0000 (16:25 +0000)
debian/changelog
src.lisp

index 0279f43b7ce943ce5c4a4022d03c967fd6e6025e..b8cecda7c2844dff2d9e31dfb7531907b8b1e73f 100644 (file)
@@ -1,3 +1,9 @@
+cl-puri (1.2.6-1) unstable; urgency=low
+
+  * Fix .parse-error
+
+ --
+
 cl-puri (1.2.5-1) unstable; urgency=low
 
   * add shrink vector, AllegroCL fixes
index 426270158992aa6587abb94a12769452991f319f..edb8afa5d8ef99b67eed37f8ac13283f9ca184ea 100644 (file)
--- a/src.lisp
+++ b/src.lisp
@@ -22,7 +22,7 @@
 ;; Original version from ACL 6.1:
 ;; uri.cl,v 2.3.6.4.2.1 2001/08/09 17:42:39 layer
 ;;
-;; $Id: src.lisp,v 1.7 2003/07/19 20:32:48 kevin Exp $
+;; $Id: src.lisp,v 1.8 2003/07/20 16:25:21 kevin Exp $
 
 (defpackage #:puri
   (:use #:cl)
@@ -63,8 +63,6 @@
   (declaim (optimize (speed 3))))
 
 
-#-(or allegro lispworks)
-(define-condition parse-error (error)  ())
 
 #-allegro
 (defun parse-body (forms &optional env)
   (subseq str 0 size))
 
 
+#-(or allegro lispworks)
+(define-condition parse-error (error)
+  ((fmt-control :initarg :fmt-control
+               :reader fmt-control)
+   (fmt-args :initarg :fmt-args
+                 :reader fmt-args))
+  (:report (lambda (c stream)
+            (format stream "Parse error: ")
+            (apply #'format stream (fmt-control c) (fmt-args c)))))
+
 #-allegro
 (defun .parse-error (fmt &rest args)
-  (error (make-condition 'parse-error :format-control fmt
-                        :format-arguments args)))
+  (error (make-condition 'parse-error :fmt-control fmt :fmt-args args)))
 
 #-allegro
 (defun internal-reader-error (stream fmt &rest args)