;;; tl-822.el --- RFC 822 parser for GNU Emacs
;;;
;;; Copyright (C) 1995 Free Software Foundation, Inc.
-;;; Copyright (C) 1995 MORIOKA Tomohiko
+;;; Copyright (C) 1995,1996 MORIOKA Tomohiko
;;;
;;; Author: MORIOKA Tomohiko <morioka@jaist.ac.jp>
;;; Keywords: mail, news, RFC 822
;;;
-;;; This file is part of tm (Tools for MIME).
+;;; This file is part of tl (Tiny Library).
;;;
+;;; This program is free software; you can redistribute it and/or
+;;; modify it under the terms of the GNU General Public License as
+;;; published by the Free Software Foundation; either version 2, or
+;;; (at your option) any later version.
+;;;
+;;; This program is distributed in the hope that it will be useful,
+;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+;;; General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with This program. If not, write to the Free Software
+;;; Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;;;
+;;; Code:
(require 'tl-seq)
(require 'tl-str)
(defconst rfc822/RCS-ID
- "$Id: tl-822.el,v 7.2 1996-01-18 14:48:33 morioka Exp $")
+ "$Id: tl-822.el,v 7.3 1996-01-25 08:07:39 morioka Exp $")
(defconst rfc822/version (get-version-string rfc822/RCS-ID))
(setq lal (cdr ret))
(while (and (setq ret (rfc822/parse-token lal))
(setq dot (car ret))
- (equal (cdr (assq 'specials dot)) ".")
+ (string-equal (cdr (assq 'specials dot)) ".")
(setq ret (rfc822/parse-word (cdr ret)))
(setq local-part
(append local-part dot (cdr (car ret)))
(setq lal (cdr ret))
(while (and (setq ret (rfc822/parse-token lal))
(setq dot (car ret))
- (equal (cdr (assq 'specials dot)) ".")
+ (string-equal (cdr (assq 'specials dot)) ".")
(setq ret (rfc822/parse-sub-domain (cdr ret)))
(setq domain
(append domain dot (cdr (car ret)))
(let ((ret (rfc822/parse-token lal)) at-sign)
(if (and ret
(setq at-sign (car ret))
- (equal (cdr (assq 'specials at-sign)) "@")
+ (string-equal (cdr (assq 'specials at-sign)) "@")
(setq ret (rfc822/parse-domain (cdr ret)))
)
(cons (cons 'at-domain (append at-sign (cdr (car ret))))
(setq lal (cdr ret))
(while (and (setq ret (rfc822/parse-token lal))
(setq comma (car ret))
- (equal (cdr (assq 'specials comma)) ",")
+ (string-equal (cdr (assq 'specials comma)) ",")
(setq ret (rfc822/parse-at-domain (cdr ret)))
)
(setq route (append route comma (cdr (car ret))))
)
(and (setq ret (rfc822/parse-token lal))
(setq colon (car ret))
- (equal (cdr (assq 'specials colon)) ":")
+ (string-equal (cdr (assq 'specials colon)) ":")
(setq route (append route colon))
)
))
< route addr-spec >)
(if (and ret
(setq < (car ret))
- (equal (cdr (assq 'specials <)) "<")
+ (string-equal (cdr (assq 'specials <)) "<")
(setq lal (cdr ret))
(progn (and (setq ret (rfc822/parse-route lal))
(setq route (cdr (car ret)))
(setq lal (cdr ret))
(setq ret (rfc822/parse-token lal))
(setq > (car ret))
- (equal (cdr (assq 'specials >)) ">")
+ (string-equal (cdr (assq 'specials >)) ">")
)
(cons (cons 'route-addr (append route addr-spec))
(cdr ret)
(setq lal (cdr ret))
(setq ret (rfc822/parse-token lal))
(setq colon (car ret))
- (equal (cdr (assq 'specials colon)) ":")
+ (string-equal (cdr (assq 'specials colon)) ":")
(setq lal (cdr ret))
(progn
(and (setq ret (rfc822/parse-mailbox lal))
(progn
(while (and (setq ret (rfc822/parse-token lal))
(setq comma (car ret))
- (equal (cdr (assq 'specials comma)) ",")
+ (string-equal
+ (cdr (assq 'specials comma)) ",")
(setq lal (cdr ret))
(setq ret (rfc822/parse-mailbox lal))
(setq mbox (cons (car ret) mbox))
)))
(and (setq ret (rfc822/parse-token lal))
(setq semicolon (car ret))
- (equal (cdr (assq 'specials semicolon)) ";")
+ (string-equal (cdr (assq 'specials semicolon)) ";")
)))
(cons (list 'group phrase (reverse mbox))
(cdr ret)
(let ((dest (list (car ret))))
(setq lal (cdr ret))
(while (and (setq ret (rfc822/parse-token lal))
- (equal (cdr (assq 'specials (car ret))) ",")
+ (string-equal (cdr (assq 'specials (car ret))) ",")
(setq ret (rfc822/parse-address (cdr ret)))
)
(setq dest (cons (car ret) dest))
;;;
(provide 'tl-822)
+
+;;; tl-822.el ends here