X-Git-Url: http://cgit.sxemacs.org/?a=blobdiff_plain;f=lisp%2Fietf-drums.el;h=645a79ad55a5558193f3cc8921e60e2d1984b1df;hb=904183d6d0dca89f7bdc7c6081ddd89b64d644ef;hp=07fbc460f7a61ad5c29cf62ce6c2d3908835165f;hpb=87ef63c17a4cfc0ba0a3870d8a8ca3231bc6ee63;p=gnus diff --git a/lisp/ietf-drums.el b/lisp/ietf-drums.el index 07fbc460f..645a79ad5 100644 --- a/lisp/ietf-drums.el +++ b/lisp/ietf-drums.el @@ -1,5 +1,5 @@ ;;; ietf-drums.el --- Functions for parsing RFC822bis headers -;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003 +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004 ;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen @@ -27,6 +27,16 @@ ;; Messages". This library is based on ;; draft-ietf-drums-msg-fmt-05.txt, released on 1998-08-05. +;; Pending a real regression self test suite, Simon Josefsson added +;; various self test expressions snipped from bug reports, and their +;; expected value, below. I you believe it could be useful, please +;; add your own test cases, or write a real self test suite, or just +;; remove this. + +;; +;; (ietf-drums-parse-address "'foo' ") +;; => ("foo@example.com" . "'foo'") + ;;; Code: (eval-when-compile (require 'cl)) @@ -64,9 +74,9 @@ backslash and doublequote.") (modify-syntax-entry ?> ")" table) (modify-syntax-entry ?@ "w" table) (modify-syntax-entry ?/ "w" table) - (modify-syntax-entry ?* " " table) - (modify-syntax-entry ?\; " " table) - (modify-syntax-entry ?\' " " table) + (modify-syntax-entry ?* "_" table) + (modify-syntax-entry ?\; "_" table) + (modify-syntax-entry ?\' "_" table) (if (featurep 'xemacs) (let ((i 128)) (while (< i 256) @@ -133,7 +143,7 @@ backslash and doublequote.") (forward-sexp 1)) ((eq c ?\() (forward-sexp 1)) - ((memq c '(? ?\t ?\n)) + ((memq c '(?\ ?\t ?\n)) (delete-char 1)) (t (forward-char 1)))) @@ -270,4 +280,5 @@ backslash and doublequote.") (provide 'ietf-drums) +;;; arch-tag: 379a0191-dbae-4ca6-a0f5-d4202c209ef9 ;;; ietf-drums.el ends here