`ew-permit-null-encoded-text' checking.
* ew-quote.el (ew-quote-concat): Use `ew-encoded-word-regexp'
instead of `ew-encoded-word-regexp0'.
(ew-quote-sole): Ditto.
* ew-var.el (ew-encoded-text-regexp): Reverted.
(ew-encoded-text-regexp0): Abolished
(ew-encoded-text-regexp1): Abolished
(ew-encoded-word-regexp): Reverted.
(ew-encoded-word-regexp0): Abolished
(ew-encoded-word-regexp1): Abolished
(ew-anchored-encoded-word-regexp): Use `ew-encoded-word-regexp'.
(ew-type2-regexp): Use `ew-encoded-word-regexp'.
+1998-09-02 Tanaka Akira <akr@jaist.ac.jp>
+
+ * ew-data.el (ew-separate-eword): Remove
+ `ew-permit-null-encoded-text' checking.
+
+ * ew-quote.el (ew-quote-concat): Use `ew-encoded-word-regexp'
+ instead of `ew-encoded-word-regexp0'.
+ (ew-quote-sole): Ditto.
+
+ * ew-var.el (ew-encoded-text-regexp): Reverted.
+ (ew-encoded-text-regexp0): Abolished
+ (ew-encoded-text-regexp1): Abolished
+ (ew-encoded-word-regexp): Reverted.
+ (ew-encoded-word-regexp0): Abolished
+ (ew-encoded-word-regexp1): Abolished
+ (ew-anchored-encoded-word-regexp): Use `ew-encoded-word-regexp'.
+ (ew-type2-regexp): Use `ew-encoded-word-regexp'.
+
1998-09-01 Tanaka Akira <akr@jaist.ac.jp>
* TESTPAT: Add a notice about null encoded-text.
(defun ew-separate-eword (frag1 frag2 targets)
(while (not (eq frag1 frag2))
(when (and (memq (get frag1 'type) targets)
- (string-match (if ew-permit-null-encoded-text
- ew-encoded-word-regexp0
- ew-encoded-word-regexp1)
+ (string-match ew-encoded-word-regexp
(symbol-name frag1))
(or (< 0 (match-beginning 0))
(< (match-end 0) (length (symbol-name frag1)))))
(setq frag (cadr result)))
(put frag 'prev-frag (get frag1 'prev-frag))
(put (get frag1 'prev-frag) 'next-frag frag)
- (while (string-match (if ew-permit-null-encoded-text
- ew-encoded-word-regexp0
- ew-encoded-word-regexp1)
- atom start)
+ (while (string-match ew-encoded-word-regexp atom start)
(when (< start (match-beginning 0))
(setq frag (make-symbol (substring atom start (match-beginning 0)))
result (ew-rcons* result frag))
(while tmp
(setq str (car tmp)
start 0)
- (while (string-match ew-encoded-word-regexp0 str start)
+ (while (string-match ew-encoded-word-regexp str start)
(setq eword-start (match-beginning 0)
charset-start (match-beginning 1)
eword-end (match-end 0))
(defun ew-quote-sole (str gen-type2)
(let (result (start 0) charset-start quoting-end eword-end l)
- (while (string-match ew-encoded-word-regexp0 str start)
+ (while (string-match ew-encoded-word-regexp str start)
(setq charset-start (match-beginning 1)
eword-end (match-end 0))
(string-match ew-quoting-chars-regexp str charset-start)
;;; constants.
(defconst ew-token-regexp "[-!#-'*+0-9A-Z^-~]+")
-(defconst ew-encoded-text-regexp0 "[!->@-~]*")
-(defconst ew-encoded-text-regexp1 "[!->@-~]+")
+(defconst ew-encoded-text-regexp "[!->@-~]*")
-(defconst ew-encoded-word-regexp0
+(defconst ew-encoded-word-regexp
(concat (regexp-quote "=?")
"\\(" ew-token-regexp "\\)"
(regexp-quote "?")
"\\(" ew-token-regexp "\\)"
(regexp-quote "?")
- "\\(" ew-encoded-text-regexp0 "\\)"
- (regexp-quote "?=")))
-
-(defconst ew-encoded-word-regexp1
- (concat (regexp-quote "=?")
- "\\(" ew-token-regexp "\\)"
- (regexp-quote "?")
- "\\(" ew-token-regexp "\\)"
- (regexp-quote "?")
- "\\(" ew-encoded-text-regexp1 "\\)"
+ "\\(" ew-encoded-text-regexp "\\)"
(regexp-quote "?=")))
(defconst ew-anchored-encoded-word-regexp
- (concat "\\`" ew-encoded-word-regexp0 "\\'"))
+ (concat "\\`" ew-encoded-word-regexp "\\'"))
(defconst ew-b-regexp
(eval-when-compile
(regexp-quote "?")
"\\(" ew-token-regexp "\\)"
(regexp-quote "?")
- "\\(" ew-encoded-text-regexp0 "\\)"
+ "\\(" ew-encoded-text-regexp "\\)"
(regexp-quote "?")
"\\'"))