;ELC   
;;; compiled by amu@mit.edu on Sat Sep 13 16:20:22 1997
;;; from file /afs/sipb.mit.edu/contrib/emacs/packages/gnus-5.4.67/lisp/nndoc.el
;;; emacs version 19.30.1.
;;; bytecomp version FSF 2.10
;;; optimization is on.
;;; this file uses opcodes which do not exist in Emacs 18.

(if (and (boundp 'emacs-version)
	 (or (and (boundp 'epoch::version) epoch::version)
	     (string-lessp emacs-version "19.29")))
    (error "`nndoc.el' was compiled for Emacs 19.29 or later"))


(byte-code "ÀÁ!ˆÀÂ!ˆÀÃ!ˆÀÄ!ˆÅÆÇÈ\"È‰F	B	ÅÊDBÈ‡" [require nnheader message nnmail nnoo nndoc mapcar #[(p) "C‡" [p] 1] nil nnoo-definition-alist "*internal-non-initialized-backend*" nnoo-state-alist] 4)
#@195 *Type of the file.
One of `mbox', `babyl', `digest', `news', `rnews', `mmdf', `forward',
`rfc934', `rfc822-forward', `mime-digest', `standard-digest',
`slack-digest', `clari-briefs' or `guess'.
(defvar nndoc-article-type (quote guess) (#$ . -697))
(nnoo-define (quote nndoc-article-type) nil)
#@47 *Whether the nndoc group is `mail' or `post'.
(defvar nndoc-post-type (quote mail) (#$ . -996))
(byte-code "ÀÁÂ\"ˆÃÄ!„7 ÅÆÇÈÉÊËÌÍÎÏÐÑÒÓ\"ÔQBÕÖÑ×Ó\"ÔQBØBBBÙBBBBBBBBBBÄBÃÛ!„F ÂÛBÀÛÂ\"ˆÃÜ!„Z ÂÜBÀÜÂ\"ˆÃÝ!„n ÂÝBÀÝÂ\"ˆÃÞ!„‚ ÂÞBÀÞÂ\"ˆÃß!„– ÂßBÀßÂ\"ˆÃà!„ª Â àBÀàÂ\"ˆÃá!„¾ Â!áBÀáÂ\"ˆÃâ!„Ò Â\"âBÀâÂ\"ˆÃã!„æ Â#ãBÀãÂ\"ˆÃä!„ú Â$äBÀäÂ\"ˆÃå!„Â%åBÀåÂ\"ˆÃæ!„\"Â&æBÀæÂ\"ˆÃç!„6Â'çBÀçÂ\"ˆÃè!„JÂ(èBÀèÂ\"ˆÃé!„^Â)éBÀéÂ\"ˆÃê!„rÂ*êBÀêÂ\"ˆÃë!„†Â+ëBÀëÂ\"ˆÃì!„ší,ìBÀìÂ\"ˆÃî!„®Â.îBÀîÂ\"‡" [nnoo-define nndoc-post-type nil boundp nndoc-type-alist (mmdf (article-begin . "^\n") (body-end . "^\n")) (news (article-begin . "^Path:")) (rnews (article-begin . "^#! *rnews +\\([0-9]+\\) *\n") (body-end-function . nndoc-rnews-body-end)) (mbox (article-begin-function . nndoc-mbox-article-begin) (body-end-function . nndoc-mbox-body-end)) (babyl (article-begin . "\f *\n") (body-end . "") (body-begin-function . nndoc-babyl-body-begin) (head-begin-function . nndoc-babyl-head-begin)) (forward (article-begin . "^-+ Start of forwarded message -+\n+") (body-end . "^-+ End of forwarded message -+$") (prepare-body-function . nndoc-unquote-dashes)) (rfc934 (article-begin . "^--.*\n+") (body-end . "^--.*$") (prepare-body-function . nndoc-unquote-dashes)) (clari-briefs (article-begin . "^ \\*") (body-end . "^	------*[ 	]^*\n^ \\*") (body-begin . "^	") (head-end . "^	") (generate-head-function . nndoc-generate-clari-briefs-head) (article-transform-function . nndoc-transform-clari-briefs)) (mime-digest (article-begin . "") (head-end . "^ ?$") (body-end . "") (file-end . "") (subtype digest guess)) standard-digest first-article "^" make-string 70 45 "\n\n+" article-begin "^\n" 30 ((prepare-body-function . nndoc-unquote-dashes) (body-end-function . nndoc-digest-body-end) (head-end . "^ ?$") (body-begin . "^ ?\n") (file-end . "^End of .*digest.*[0-9].*\n\\*\\*\\|^End of.*Digest *$") (subtype digest guess)) ((slack-digest (article-begin . "^------------------------------*[\n 	]+") (head-end . "^ ?$") (body-end-function . nndoc-digest-body-end) (body-begin . "^ ?$") (file-end . "^End of") (prepare-body-function . nndoc-unquote-dashes) (subtype digest guess)) (lanl-gov-announce (article-begin . "^\\\\\\\\\n") (head-begin . "^Paper.*:") (head-end . "\\(^\\\\\\\\.*\n\\|-----------------\\)") (body-begin . "") (body-end . "-------------------------------------------------") (file-end . "^Title: Recent Seminal") (generate-head-function . nndoc-generate-lanl-gov-head) (article-transform-function . nndoc-transform-lanl-gov-announce) (subtype preprints guess)) (rfc822-forward (article-begin . "^\n") (body-end-function . nndoc-rfc822-forward-body-end-function)) (guess (guess . t) (subtype nil)) (digest (guess . t) (subtype nil)) (preprints (guess . t) (subtype nil))) current-load-list nndoc-file-begin nndoc-first-article nndoc-article-end nndoc-article-begin nndoc-head-begin nndoc-head-end nndoc-file-end nndoc-body-begin nndoc-body-end-function nndoc-body-begin-function nndoc-head-begin-function nndoc-body-end nndoc-dissection-alist nndoc-prepare-body-function nndoc-generate-head-function nndoc-article-transform-function nndoc-article-begin-function nndoc-status-string "" nndoc-group-alist] 16)
#@28 Current nndoc news buffer.
(defvar nndoc-current-buffer nil (#$ . 4305))
(byte-code "ÀÁÂ\"ˆÃÄ!„ ÂÄBÀÄÂ\"‡" [nnoo-define nndoc-current-buffer nil boundp nndoc-address current-load-list] 3)
#@16 nndoc version.
(defconst nndoc-version "nndoc 1.0" (#$ . 4503))
(nnoo-define-basics-1 (quote nndoc))
(defalias 'nndoc-retrieve-headers #[(articles &optional newsgroup server fetch-old) "À	\n\"…{ ŠqˆÄ ˆÅ‰@;ƒ É‚z ƒv ‰A@‰\nžA‰ƒ ËÌ\"cˆƒM !ˆ‚Y Î@A@#ˆdbˆ`SfÐU„g ÑcˆËÒÓ8\"cˆÔcˆ‚ Õ ˆÉ+‡" [nndoc-possibly-change-buffer newsgroup server nntp-server-buffer erase-buffer nil entry article articles headers nndoc-dissection-alist format "221 %d Article retrieved.\n" nndoc-generate-head-function insert-buffer-substring nndoc-current-buffer 10 "\n" "Lines: %d\n" 4 ".\n" nnheader-fold-continuation-lines] 4])
(nnoo-register-function (quote nndoc-retrieve-headers))
(defalias 'nndoc-request-article #[(article &optional newsgroup server buffer) "À	\n\"ˆŠ† \fžAÇ	‰qˆÊ ˆ	…^ ;?…^ Ë\f	@	A@#ˆÍcˆ`Ë\fÎ	8Ï	8#ˆbˆƒS  ˆƒ] !ˆÒ,‡" [nndoc-possibly-change-buffer newsgroup server buffer nntp-server-buffer article nndoc-dissection-alist nil beg entry erase-buffer insert-buffer-substring nndoc-current-buffer "\n" 2 3 nndoc-prepare-body-function nndoc-article-transform-function t] 6])
(nnoo-register-function (quote nndoc-request-article))
#@20 Select news GROUP.
(defalias 'nndoc-request-group #[(group &optional server dont-check) "ÀÂ\f\"„ ÅÆÇ#‚> 	ƒ! ÅÆÊ#ˆË‚> \fG‰ÍUƒ7 Î!ˆÅÆÏ#‚> ÐÑ	Ò	%)‡" [nil number nndoc-possibly-change-buffer group server nnheader-report nndoc "No such file or buffer: %s" nndoc-address dont-check "Selected group %s" t nndoc-dissection-alist 0 nndoc-close-group "No articles in group %s" nnheader-insert "211 %d %d %d %s\n" 1] 6 (#$ . 5689)])
(nnoo-register-function (quote nndoc-request-group))
(defalias 'nndoc-request-type #[(group &optional article) "„ Á‡\nƒ\f \n‡Á‡" [article unknown nndoc-post-type] 1])
(nnoo-register-function (quote nndoc-request-type))
(defalias 'nndoc-close-group #[(group &optional server) "À	\n\"ˆƒ Ä!ƒ Å!ˆÆÇ	\"\"ÉÊË\n\"ˆÉ\fÍ‡" [nndoc-possibly-change-buffer group server nndoc-current-buffer buffer-name kill-buffer delq assoc nndoc-group-alist nil nnoo-close-server nndoc nndoc-dissection-alist t] 4])
(nnoo-register-function (quote nndoc-close-group))
(defalias 'nndoc-request-list #[(&optional server) "À‡" [nil] 1])
(nnoo-register-function (quote nndoc-request-list))
(defalias 'nndoc-request-newgroups #[(date &optional server) "À‡" [nil] 1])
(nnoo-register-function (quote nndoc-request-newgroups))
(defalias 'nndoc-request-list-newsgroups #[(&optional server) "À‡" [nil] 1])
(nnoo-register-function (quote nndoc-request-list-newsgroups))
(defalias 'nndoc-possibly-change-buffer #[(group source) "À\nƒ Ã\n!ƒ \nÄ\"A‰=„u 	ƒ\" 	‚u Ç!ƒ0 Ã!„D ;ƒu É!ƒu Ê!„u ËÌÍQ!‰BBÀŠ\nqˆÏp!ˆÐ ˆ;ƒo Ñ!ˆ‚t Ò!ˆ)\nƒ‰ „‰ Š\nqˆÓ ˆÔ ˆ)\n„� Õ ˆ\n)‡" [nil buf nndoc-current-buffer buffer-name assoc group nndoc-group-alist bufferp nndoc-address file-exists-p file-directory-p get-buffer-create " *nndoc " "*" nndoc-dissection-alist buffer-disable-undo erase-buffer nnheader-insert-file-contents insert-buffer-substring nndoc-set-delims nndoc-dissect-buffer nndoc-close-server] 5])
#@74 Set the nndoc delimiter variables according to the type of the document.
(defalias 'nndoc-set-delims #[nil "À	ƒ 	‰A@ÂLˆ‚ )ÂÄžA‰žƒ' Ç!‚ …> ÈÉÊ@@\"!‰A@ALˆ‚' )‡" [(nndoc-file-begin nndoc-first-article nndoc-article-end nndoc-head-begin nndoc-head-end nndoc-file-end nndoc-article-begin nndoc-body-begin nndoc-body-end-function nndoc-body-end nndoc-prepare-body-function nndoc-article-transform-function nndoc-generate-head-function nndoc-body-begin-function nndoc-head-begin-function) vars nil defs guess nndoc-article-type nndoc-type-alist nndoc-guess-type intern format "nndoc-%s"] 4 (#$ . 7622)])
(defalias 'nndoc-guess-type #[(subtype) "Á‰‰„A ‰A@‰ƒA Æ\nžA†  Ç>ƒ ebˆÈÉÊ\n@\"! ‰§ƒ \nB\fBÁ‰ƒ\f „M \f„M ËÌ!ˆƒV \n@‚] Í\fÎ\"@A@,‡" [nndoc-type-alist nil entry result results alist subtype (guess) intern format "nndoc-%s-type-p" error "Document is not of any recognized type" sort #[(r1 r2) "@	@W‡" [r1 r2] 2]] 5])
(defalias 'nndoc-mbox-type-p #[nil "À	!… Â‡" [looking-at message-unix-mail-delimiter t] 2])
(defalias 'nndoc-mbox-article-begin #[nil "ÀÁ\nPÃÄ#… Å”b‡" [re-search-forward "^" message-unix-mail-delimiter nil t 0] 4])
(defalias 'nndoc-mbox-body-end #[nil "`À‰ŠÄÅPÀÇ#…T `‰…T ÈÉÇ#…T ÄÊ	Ç#…T ËÌÍ!!‰…T ÈÉÇ#…T `\n\\‰dU?…T \ndW…T \nb…T Î!)…Z \nb+‡" [nil end len beg re-search-backward "^" message-unix-mail-delimiter t search-forward "\n\n" "^Content-Length:[ 	]*\\([0-9]+\\) *$" string-to-int match-string 1 looking-at] 4])
(defalias 'nndoc-mmdf-type-p #[nil "ÀÁ!… Â‡" [looking-at "$" t] 2])
(defalias 'nndoc-news-type-p #[nil "ÀÁ!… Â‡" [looking-at "^Path:.*\n" t] 2])
(defalias 'nndoc-rnews-type-p #[nil "ÀÁ!… Â‡" [looking-at "#! *rnews" t] 2])
(defalias 'nndoc-rnews-body-end #[nil "À	ÂÃ#… Äy… `ÅÆÄ!!\\b‡" [re-search-backward nndoc-article-begin nil t 1 string-to-int match-string] 4])
(defalias 'nndoc-babyl-type-p #[nil "ÀÁÂÃ#…	 Ã‡" [re-search-forward "\f *\n" nil t] 4])
(defalias 'nndoc-babyl-body-begin #[nil "ÀÁÂÃ#ˆÄÅ!…1 ŠÀÂÃ#)† dÀÁÃ#?…0 bˆÈyˆÉcˆÈy)‡" [re-search-forward "^\n" nil t looking-at "*** EOOH ***" nndoc-article-begin next -1 "\n"] 4])
(defalias 'nndoc-babyl-head-begin #[nil "ÀÁÂÃ#… ÄÅ!ƒ ÆyˆÃ‡" [re-search-forward "^[0-9].*\n" nil t looking-at "*** EOOH ***" 1] 4])
(defalias 'nndoc-forward-type-p #[nil "ÀÁÂÃ#…& ÀÄÂÃ#?…& ÅÆÂÃÇ$?…& ÀÆÂÃÇ$?…& Ã‡" [re-search-forward "^-+ Start of forwarded message -+\n+" nil t "^Subject:.*digest" re-search-backward "^From:" 2] 5])
(defalias 'nndoc-rfc934-type-p #[nil "ÀÁÂÃ#…& ÀÄÂÃ#?…& ÅÆÂÃÇ$?…& ÀÆÂÃÇ$?…& Ã‡" [re-search-forward "^-+ Start of forwarded.*\n+" nil t "^Subject:.*digest" re-search-backward "^From:" 2] 5])
(defalias 'nndoc-rfc822-forward-type-p #[nil "ŒÀ ˆÁÂÃÄ#… Ä)‡" [message-narrow-to-head re-search-forward "^Content-Type: *message/rfc822" nil t] 4])
(defalias 'nndoc-rfc822-forward-body-end-function #[nil "db‡" [] 1])
(defalias 'nndoc-clari-briefs-type-p #[nil "ÀÂÃÀÄ#)…\f Ä‡" [nil case-fold-search re-search-forward "^	[^a-z]+ ([^a-z]+) --" t] 4])
(defalias 'nndoc-transform-clari-briefs #[(article) "ebˆÀÁ!ƒ ÂÃÄ‰#ˆÅ!‡" [looking-at " *\\*\\(.*\\)\n" replace-match "" t nndoc-generate-clari-briefs-head article] 4])
(defalias 'nndoc-generate-clari-briefs-head #[(article) "	žAÂ‰ŠqˆŒ@Ç8}ˆebˆÈÉ!ƒ0 ÊË!ÌÍ\f\"ƒ0 \fÎ‰”OÂÐÑÂÒ#)ƒ@ ÊË!*ÓÔ†H ÕÖ×\f†O ØÙ±+‡" [article nndoc-dissection-alist nil from subject entry nndoc-current-buffer 3 looking-at " *\\*\\(.*\\)$" match-string 1 string-match "[ 	]+$" 0 case-fold-search re-search-forward "^	\\([^a-z]+\\(,[^(]+\\)? ([^a-z]+)\\) --" t "From: " "clari@clari.net (" "unknown" ")" "\nSubject: " "(no subject)" "\n"] 7])
(defalias 'nndoc-mime-digest-type-p #[nil "ÀÁ‰‰ÆÇÈPÁÀ#…= É”…= ÊÉ!Ë\fÌQÍž‰ÏÐBÑÒBÓBÔÕBÖË\f×QB¯¡ˆÀ,‡" [t nil entry b-delimiter boundary-id case-fold-search re-search-forward "^Content-Type: *multipart/digest;[ 	\n]*[ 	]" "boundary=\"\\([^\"\n]*[^\" 	\n]\\)\"" 1 match-string "\n--" "[\n 	]+" mime-digest nndoc-type-alist head-end "^ ?$" body-begin "^ ?\n" article-begin body-end-function nndoc-digest-body-end file-end "--[ 	]*$"] 10])
(defalias 'nndoc-standard-digest-type-p #[nil "ÀÁÂÃÄ\"ÅQÆÇ#… ÀÅÂÈÄ\"ÅQÆÇ#… Ç‡" [re-search-forward "^" make-string 70 45 "\n\n" nil t 30] 5])
(defalias 'nndoc-digest-body-end #[nil "À	ÂÃ#… Ä”b‡" [re-search-forward nndoc-article-begin nil t 0] 4])
(defalias 'nndoc-slack-digest-type-p #[nil "À‡" [0] 1])
(defalias 'nndoc-lanl-gov-announce-type-p #[nil "ÀÂÃÀÄ#)…\f Ä‡" [nil case-fold-search re-search-forward "^\\\\\\\\\nPaper: [a-z-]+/[0-9]+" t] 4])
(defalias 'nndoc-transform-lanl-gov-announce #[(article) "dbˆÀÁÂÃ#… ÄÅÃÂ#‡" [re-search-backward "^\\\\\\\\ +(\\([^ ]*\\) , *\\([^ ]*\\))" nil t replace-match "\n\nGet it at \\1 (\\2)"] 4])
(defalias 'nndoc-generate-lanl-gov-head #[(article) "	žAÂÃ‰ŠqˆŒ@A@}ˆebˆÉÊ!ƒP ËÌÍ!ÎQÏÐÃÑ#ƒ9 ÌÍ!ÏÒÃÑ#ƒP ÌÍ!PÌÓ!ÔÕR*\fƒg Ö×\f\"ƒg ØÙÑ‰\f$‰„U Ú\f†m ÛÜ†s ÝÞ±,‡" [article nndoc-dissection-alist "no address given" nil from subject e-mail entry nndoc-current-buffer looking-at "^Paper.*: \\([a-z-]+/[0-9]+\\)" " (" match-string 1 ")" re-search-forward "^From: \\([^ ]+\\)" t "^Title: \\([^\f]*\\)\nAuthors?: \\(.*\\)" 2 " <" ">" string-match "([^)]*)" replace-match "" "From: " "unknown" "\nSubject: " "(no subject)" "\n"] 6])
(defalias 'nndoc-search #[(regexp) "À	ÂÃ#Äyˆ‡" [re-search-forward regexp nil t 0] 4])
#@70 Go through the document and partition it into heads/bodies/articles.
(defalias 'nndoc-dissect-buffer #[nil "ÀÁÂ‰‰‰Â	Š\nqˆebˆƒ$ Ì!ˆƒ5 ƒ5 Ì!‚7 Î …Û ÂƒI  ˆ‚S ƒS Ì!ˆ`dY„e ƒk Ò!ƒk dbˆ‚$ `Ì†u Ô!ˆ`ƒ…  ˆ‚Ž Ì†Œ ×!ˆ`ƒ›  „À ƒ§ Ì!„À Î „À dbˆƒÀ ÚÂÁ#ƒÀ Àyˆ`T‰\fÛ\f\"¯	B	‚$ .‡" [0 t nil body-end body-begin head-end head-begin first i nndoc-dissection-alist nndoc-current-buffer nndoc-file-begin nndoc-search nndoc-first-article nndoc-article-begin nndoc-head-begin-function nndoc-head-begin nndoc-file-end looking-at nndoc-head-end "^$" nndoc-body-begin-function nndoc-body-begin "^\n" nndoc-body-end-function nndoc-body-end re-search-backward count-lines] 8 (#$ . 12964)])
(defalias 'nndoc-article-begin #[nil "ƒ  ‡ÁÂÃ�‡" [nndoc-article-begin-function G77731 (nndoc-search nndoc-article-begin) ((error))] 3])
#@43 Unquote quoted non-separators in digests.
(defalias 'nndoc-unquote-dashes #[nil "ÀÁÂÃ#… ÄÅÃ‰#ˆ‚  ‡" [re-search-forward "^- -" nil t replace-match "-"] 4 (#$ . 13842)])
#@266 Add document DEFINITION to the list of nndoc document definitions.
If POSITION is nil or `last', the definition will be added
as the last checked definition, if t or `first', add as the
first definition, and if any other symbol, add after that
symbol in the alist.
(defalias 'nndoc-add-type #[(definition &optional position) "À	@\nž\n\"ƒ Ä=ƒ \n	C¤‰‡Å=„% Æ=ƒ+ 	\nB‰‡\nž\n>‰„; ÈÉ\"ˆ	AB¡)‡" [delq definition nndoc-type-alist position last t first list error "No such position: %s"] 4 (#$ . 14018)])
(provide (quote nndoc))
