%PDF- %PDF-
Direktori : /usr/local/share/emacs/27.2/lisp/textmodes/ |
Current File : //usr/local/share/emacs/27.2/lisp/textmodes/reftex-parse.elc |
;ELC ;;; Compiled ;;; in Emacs version 27.2 ;;; with all optimizations. ;;; This file uses dynamic docstrings, first added in Emacs 19.29. ;;; This file does not contain utf-8 non-ASCII characters, ;;; and so can be loaded in Emacs versions earlier than 23. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (require 'reftex) (defalias 'reftex-with-special-syntax '(macro . #[(&rest body) "\301\302\303\304\305\301\306BBE\307BBE\207" [body let ((saved-syntax (syntax-table))) unwind-protect progn (set-syntax-table reftex-syntax-table) ((case-fold-search nil)) ((set-syntax-table saved-syntax))] 8])) #@21 Re-parse this file. (defalias 'reftex-parse-one #[nil "\301\302\303!)\207" [reftex-enable-partial-scans t reftex-access-scan-info (4)] 2 (#$ . 702) nil]) #@27 Re-parse entire document. (defalias 'reftex-parse-all #[nil "\300\301!\207" [reftex-access-scan-info (16)] 2 (#$ . 863) nil]) #@71 Do a document rescan. When allowed, do only a partial scan from FILE. (defalias 'reftex-do-parse #[(rescan &optional file) "\306\267\202 \307\202 \310\202 \307\202 \310\202 \310 \204 \310\nJ\311 \312\f!\313\314\f!!':\2066 \315 :\312:!;\316\236\317\236A<\320\211=\320\211>?\307=\203o \321:D\235\203m \322:D\235\204o \310; \230\203x \310\323\267\202\213 :\206\216 \f\202\216 \f\202\216 \324\325!=\310\232\203\231 \320<\326\327\321=D#@\326\330\321=D#\331@\"\210\310=\203\301 \332\333!\210\202\307 \332\334=\"\210\335 A\336\216\337B!\210\320C\340 D\341\216\212\342\216\343=>'#>.\332\344!\210>\237>\345>\310=#>\346>\236\204\f\346\320B>B>\347>\236\204\347'B>B>\316>\236\204-\316AB>B>\321>\236>>E\321EA\236FE\205DF??(\350>\236\206Z\350(D>B\211>@\211G(\320B\241\210,<\203p\351<\352\"<\317>\236\211H\203\203H<\241\210\202\214\317<B>B>)\353>\236\204\322\354\355>\"I\356\357I\"J\360\320J\"J\360\320\356\361J\"\"\211K\203\303\362\363\364K\365#\366Q\202\304\367L\353JLE>B>-\n>L\210\370\n\371\307#.\f\207" [rescan reftex-enable-partial-scans reftex-docstruct-symbol old-list master true-master #s(hash-table size 4 test equal rehash-size 1.5 rehash-threshold 0.8125 purecopy t data (t 6 1 10 (4) 14 (16) 18)) t 1 reftex-TeX-master-file file-truename file-name-as-directory file-name-directory buffer-file-name bibview-cache index-tags nil bof eof #s(hash-table size 2 test eq rehash-size 1.5 rehash-threshold 0.8125 purecopy t data (t 126 1 135)) error "This should not happen (reftex-do-parse)" reftex-last-assoc-before-elt toc appendix reftex-init-section-numbers message "Scanning entire document..." "Scanning document from %s..." syntax-table #[nil "\301!\207" [saved-syntax set-syntax-table] 2] set-syntax-table current-window-configuration #[nil "\301!\207" [#1=#:wconfig set-window-configuration] 2] #[nil "\300 \207" [reftex-kill-temporary-buffers] 1] reftex-parse-from-file "Scanning document... done" reftex-replace-label-list-segment label-numbers master-dir is-multi sort string< xr reftex-all-assq xr-doc mapcar #[(x) "\303\3048\305 #\211\203 A@\nB\207\306\307\3048\"\210\310\207" [x master-dir tmp reftex-locate-file 2 "tex" message "Can't find external document %s" nil] 4] delq car "\\`\\(" mapconcat identity "\\|" "\\)" "\\\\\\\\\\\\" put modified file true-file reftex--index-tags from-file docstruct tmp reftex-active-toc saved-syntax reftex-syntax-table case-fold-search #1# bof1 bof2 entry index-tag-cell allxr alist allprefix regexp] 6 (#$ . 995)]) (defalias 'reftex-everything-regexp #[nil "\203 \207\n\207" [reftex-support-index reftex-everything-regexp reftex-everything-regexp-no-index] 1]) #@143 Return a list of all files belonging to the current document. When RELATIVE is non-nil, give file names relative to directory of master file. (defalias 'reftex-all-document-files #[(&optional relative) "J\306\307 !\310\311\n!P\312\211\312\313\314 \"\211\203E A@ >A\203= \315\"\203= \316\317\225\"\fB\202 \f\237.\207" [reftex-docstruct-symbol all master-dir re file-list tmp file-name-directory reftex-TeX-master-file "\\`" regexp-quote nil assoc bof string-match substring 0 file relative] 4 (#$ . 3748)]) #@53 Scan the buffer for labels and save them in a list. (defalias 'reftex-parse-from-file #[(file docstruct master-dir) "\306 \307\310\211\211\311\312\310\211\211\211@ABCD\3132^\314E\315F#\211B\204; \316E!\211\203; \317!BB\204N \320EDGBG\321\313\310\"\210\212\322\323E\"\210\324BH\325=?\"\211q\210\317 E\326EDGBG\327 I\330\216\331J!\210\310K\212\214~\210\311b\210\332D\310\325#\203\373\311\225\203\343 L\203\322 \333\334\307!\307\335#\336\230\204\322 \337\340!\203\316 \337\341!\203\316 \342 M\343\216\340 *L\235\206\312 \342 M\344\216\341 *L\235?\202\317 \325\203\204 \345\334\311!EC#GBG\202\204 \346\225\2036\307\224C`Sf\347=\203\367 \350u\210NE!\211\203\204 Cf\351U\352\353E\"=\203\204 \3548\f ^ \fU\203*\322\355\356 O\"@\3578#\210GBGP\202\204 \335\225\203X\334\335!@\360\310\361\362Q\"\"\204\204 \363@GF#G\202\204 \364\225\203m\365\310\325\"\210\366\325BGBG\202\204 \367\225\203\242R\203\204 \370E!\211\203\204 \nA@\211ST\235\203\221T\202\226STB)T\nGBG\202\204 \371\225\203\362\212\334\371!U\371\225b\210\342 M\372\216\373\374U!!*V\375UW\"A@\211X\203\325\307\225b\210\202\334\371\225b\210\376 \210\345VEC\310\211%\211YGBG-\202\204 \377\201Z !\210\202\204 \201[ F!\211A\203\201\\ ABGBG\311b\210\332\201] \310\325#\203*\201^ EBGBG\311b\210\332\201_ \310\325#\203K\201` \334\201a !\334\346!EGBG\202-\201b EDGBG.\201c !0\210G.\207" [buf next-buf index-entry toc-entry highest-level level reftex-everything-regexp 0 nil 1 100 exit reftex-locate-file "tex" reftex-get-buffer-visiting buffer-file-name file-error throw message "Scanning file %s" reftex-get-file-buffer-force t bof syntax-table #[nil "\301!\207" [saved-syntax set-syntax-table] 2] set-syntax-table re-search-forward substring reftex-match-string 7 "\\label{" fboundp TeX-current-macro LaTeX-current-environment match-data #[nil "\301\302\"\207" [save-match-data-internal set-match-data evaporate] 3] #[nil "\301\302\"\207" [save-match-data-internal set-match-data evaporate] 3] reftex-label-info 3 92 -1 37 string-suffix-p ".dtx" 5 "Scanning %s %s ..." rassoc 6 delq mapcar #[(x) "\302 \"\207" [x include-file string-match] 3] reftex-parse-from-file 9 reftex-init-section-numbers appendix 10 reftex-index-info 11 #[nil "\301\302\"\207" [save-match-data-internal set-match-data evaporate] 3] reftex-no-props reftex-nth-arg-wrapper assoc reftex-move-over-touching-args error include-file tmp file-found bound regexp file master-dir docstruct reftex-keep-temporary-buffers saved-syntax reftex-syntax-table case-fold-search reftex-label-ignored-macros-and-environments save-match-data-internal reftex-section-info-function reftex-section-levels-all reftex-active-toc reftex-no-include-regexps reftex-support-index #1=#:va reftex--index-tags mac label reftex-env-or-mac-alist typekey entry "This should not happen (reftex-parse-from-file)" reftex-locate-bibliography-files bib "\\(\\`\\|[\n ]\\)[ ]*\\\\begin{thebibliography}" thebib "[\n ][ ]*\\\\externaldocument\\(\\[\\([^]]*\\)\\]\\)?{\\([^}]+\\)}" xr-doc 2 eof reftex-kill-temporary-buffers] 12 (#$ . 4288)]) #@61 Return non-nil if we are using biblatex rather than bibtex. (defalias 'reftex-using-biblatex-p #[nil "\301\300!\203\n \302\235\207\212\303\304\305\306#)\207" [TeX-active-styles boundp "biblatex" re-search-forward "^[^%\n]*?\\\\usepackage.*{biblatex}" nil t] 4 (#$ . 7444)]) #@59 Scan buffer for bibliography macros and return file list. (defalias 'reftex-locate-bibliography-files #[(master-dir &optional files) "\2045 \212eb\210\304 \305 \2034 \306\307\310\311\312#\313Q\314\305#\2034 \315\316\317\320!\321\"\"\n\204 \314\211\204 +\205B \322\323\"\324\314\"\207" [files again using-biblatex reftex-bibliography-commands reftex-using-biblatex-p t re-search-forward "\\(^\\)[^%\n ]*\\\\\\(" mapconcat identity "\\|" "\\)\\(\\[.+?\\]\\)?{[ ]*\\([^}]+\\)" nil append split-string reftex-match-string 4 "[ \n ]*,[ \n ]*" mapcar #[(x) " \235\206 \304\305\306\307\n\"\"?\205 \310\311#\207" [x reftex-bibfile-ignore-list reftex-bibfile-ignore-regexps master-dir delq nil mapcar #[(re) "\302 \"\207" [re x string-match] 3] reftex-locate-file "bib"] 5] delq] 7 (#$ . 7725)]) #@215 Replace the segment in OLD which corresponds to INSERT. Works with side effects, directly changes old. If ENTIRELY is t, just return INSERT. This function also makes sure the old toc markers do not point anywhere. (defalias 'reftex-replace-label-list-segment #[(old insert &optional entirely) "\203\f \306 \211G\"\210\n\207 \n@A@\307\fD \235\310\fD \235\f\311 \f\203, \2043 \312\313!\210\202U \306\f\211G GZ\"\210 G\fGZ\211 \233\nA\241\210GS\233 A\241\210-\207" [entirely old insert new file eof-list reftex-silence-toc-markers eof bof nil error "Cannot splice" bof-list n] 5 (#$ . 8541)]) #@115 Return a section entry for the current match. Careful: This function expects the match-data to be still in place! (defalias 'reftex-section-info #[(file) "\306 \307\224S\310\223\311\307!\312 \313\216\314\315 \"\205 \316\317 \"*\320 \f\"A\2119\2034 \312 \321\216 *\2025 $\307\225f\322U\211%\206F $\323W&\324$!$\325$&\"'\312 \326\216\212\327!+(\330\307\224Sd\331\323\225(G\317#^\")\332(!*\333+$_\334\",A@\205\214 '\335P\203\230 \336!\337P\202\231 \340*R*\341\342*-$')\343!\257 .\f\207" [marker macro save-match-data-internal prefix reftex-section-levels-all level-exp make-marker 3 nil reftex-match-string match-data #[nil "\301\302\"\207" [save-match-data-internal set-match-data evaporate] 3] string-match "begin{\\([^}]+\\)}" match-string 1 assoc #[nil "\301\302\"\207" [save-match-data-internal set-match-data evaporate] 3] 42 0 abs reftex-section-number #[nil "\301\302\"\207" [save-match-data-internal set-match-data evaporate] 3] reftex-context-substring buffer-substring-no-properties + reftex-nicify-text make-string 32 " " capitalize ": " "" toc "toc" marker-position level star unnumbered section-number text1 literal text reftex-level-indent reftex-label-menu-flags file] 11 (#$ . 9153)]) #@156 When index support is turned off, ask to turn it on and set the current prefix argument so that `reftex-access-scan-info' will rescan the entire document. (defalias 'reftex-ensure-index-support #[(&optional abort) "\203 \303\207\304\305!\203 \306\307\211\207\n\203 \310\311!\207\312\311!\210\313 \210\314\315!\207" [reftex-support-index current-prefix-arg abort t y-or-n-p "Turn on index support and rescan entire document? " demanded (16) error "No index support" message ding sit-for 1] 2 (#$ . 10402)]) (defalias 'reftex-index-info-safe #[(file) "\304 \305\216\306 !\210\307\310!+\207" [saved-syntax reftex-syntax-table case-fold-search file syntax-table #[nil "\301!\207" [saved-syntax set-syntax-table] 2] set-syntax-table nil reftex-index-info] 2]) #@114 Return an index entry for the current match. Careful: This function expects the match-data to be still in place! (defalias 'reftex-index-info #[(file) "\3062\344 \307\310!\310\224\310\225\311\"\206 \312\306\313\"\314\f8\315 !\205- \205- \312\306\313\" \fA@!\316\f8\"!;\203D !\202\\ !\250\203[ \nb\210\317!\320\f8\"\206\\ \321\202\\ \321#\nb\210\317\322\f8\320\f8\"\206m \323$\nb\210\324 \210`%\325\313w\210`& b\210\326\313x\210`'\327'&\"(\330)$\"\205\235 \331\224T*\332$\331*#+\"\203\265 \"+P\202\267 +\211,\227-\333\334\335,.\"\336#/%b\210\337#(0 $,/-*\257\n.0\207" [macro bom boa reftex-index-macro-alist entry exclude exit reftex-match-string 10 assoc throw nil 3 fboundp 2 reftex-nth-arg 6 "idx" 5 "" reftex-move-over-touching-args "^ \n " "^ \n" buffer-substring-no-properties string-match 0 substring mapconcat identity split-string " ! " index test-dummy itag prefix index-tag arg end-of-args end-of-context begin-of-context context reftex-index-key-end-re key-end rawkey key sortkey reftex-index-level-re showkey file] 11 (#$ . 11174)]) #@73 Get about one line of useful context for the label definition at point. (defalias 'reftex-short-context #[(env parse &optional bound derive) ":\203 \203 A\202 @\306\204 \212\307 )\202\306 \310=\203n \n\311\230\203Y \212\312e\310#\203@ \313\225\203@ \314\225b\210\307 \202U \f\203T \315\316\317\f8\"\210\320\321\317\f8\"\202U \322)\202\306 \212 b\210\323\n!\324=\204h \325 \210\307 )\202\306 ;\203\213 \212\312 \310#\203\206 \314\225b\210\307 \202\207 \326)\202\306 \250\203\246 \212 b\210\327\330\331\n!\"8\")\206\306 \332\202\306 \333!\203\305 \212\3341\270 \n!0\202\301 \"\335\336\"A\"))\202\306 \337!\207" [parse derive env reftex-section-or-include-regexp reftex-active-toc reftex-default-context-position reftex-nicify-text reftex-context-substring t "section" re-search-backward 2 0 string-match "{\\([^}]*\\)" 7 match-string 1 "SECTION HEADING NOT FOUND" string-to-char 92 reftex-move-over-touching-args "NO MATCH FOR CONTEXT REGEXP" reftex-nth-arg 6 assoc "" fboundp (error) format "HOOK ERROR: %s" "INVALID VALUE OF PARSE" bound reftex-env-or-mac-alist error-var] 7 (#$ . 12278)]) #@162 Return the docstruct entry above point. Actually returns a cons cell in which the cdr is a flag indicating if the information is exact (t) or approximate (nil). (defalias 'reftex-where-am-I #[nil "J\306\307\211\211\212\204\277\fT\310\311 \307\312#\211\2049 \313\314 D \235@\206\272\315\211?\206\272\313 \236\206\272\316\202\272\317\225\203H \320\321\317!J\"\202\272\322\225\203\322 \322\224Sb\210\313\314 D \235*\323\314 D*\235@+\307,*\203\314 +*@=\204\314 *@@\324=\203\302 \314 \322*@8\230\203\302 `\325\326*@8!\203\236 \327\326*@8!\206\243 \330*@8\232\203\262 *@,\307*\202\302 \331\332\333*@8!!\203\302 *@*\211A*\210\202g ,+\202\272\333\225\203\351 \323\334\321\333!\335\336 \236A#D \235@\202\272\337\225\203\365 \340J\236\202\272\341\225\203\236-\205\272\212\342\307!).\313\314 D \235*\323\314 D*\235@+\307\211/0\3071\3062*\203w+*@=\204w*@@\343=\203n\315.8\315*@8\230\203n2T2\344`\326*@8Z!/0\203e/0W\203n/0*@1*A\211*\204)2\317U\204\205/\306\232\203\2121\202\2312\317V\203\230\3151\202\231\307.\202\272\345\225\203\267\212\345\225b\210\320\346\347\321\345!!!J\")\202\272\350\351!\211\203 )\204\314\n\203\314\n\315\f-\317=B\207" [reftex-docstruct-symbol found rtn-if-no-other rtn cnt docstruct 0 nil re-search-backward reftex-everything-regexp t bof buffer-file-name 2 corrupted 1 assoc reftex-match-string 3 eof toc markerp 4 marker-position 8 looking-at reftex-make-regexp-allow-for-ctrl-m 7 reftex-locate-file "tex" master-dir 9 appendix 10 reftex-index-info-safe index abs 11 reftex-no-props reftex-nth-arg-wrapper error "This should not happen (reftex-where-am-I)" list endelt rtn1 reftex-support-index index-info dist last-dist last n] 7 (#$ . 13397)]) #@70 Hook to handshake with RefTeX after something new has been inserted. (defalias 'reftex-notice-new #[(&optional n force) "\3061t\3072r\204 \310\307\311\"\210\312 \210 J\311\211\311\211&\311\211'(\311\211)*\212\313\314 \311\315+\2068 \316$\205o\317 \211\204H \310\307\311\"\210,\204W A\204W \310\307\311\"\210@\n>\211\204e \310\307\311\"\210\320\321@\n#-\320\304@\n#@@\304=\203\204 \322\311\315\"\210\202\212 \322-\f\"\210\323\314 \311\315#\205o\316\225\203\260 \324\325\316!\". \211/./AB\241*\202o\326\225\203O\326\225f\327U'\330\331 !&\332&8( \2110&0AB\241\210)1A@\204\341 \310\307\311\"\210 A\321 A\236 >\211\205o @\211&\205o\332&8(Y\205o\333\334\335&8\"'\336&8*\337\332&8'\")\333\340*\"\203\344 \f\2045\341\342\336!!\343Y\2035\310\307\311\"\210&AA\2112\342\316*\")\342\326*\"Q\240\210)\202\344 \344\225\205o3\205o\345!\211&\205o \2114&4AB\241).\n00\207\210\311\207" [reftex-mode reftex-docstruct-symbol docstruct here-I-am appendix tail (error) exit throw nil reftex-access-scan-info re-search-backward reftex-everything-regexp t 1 reftex-where-am-I reftex-last-assoc-before-elt toc reftex-init-section-numbers re-search-forward reftex-label-info reftex-match-string 3 42 reftex-section-info buffer-file-name 5 string-match "\\*" 6 2 reftex-section-number "\\`\\([ ]*\\)\\([.0-9A-Z]+\\)\\(.*\\)" string-to-char match-string 65 10 reftex-index-info-safe entry star level section-number context n force reftex-active-toc #1=#:v #2=#:v #3=#:v reftex-label-menu-flags #4=#:c reftex-support-index #5=#:v] 7 (#$ . 15166)]) #@196 Assuming that we are in front of a macro argument, move backward to the closing parenthesis of the previous argument. This function understands the splitting of macros over several lines in TeX. (defalias 'reftex-move-to-previous-arg #[(&optional bound) "h\302>\206 \203 \303\304 \305#\203 \306\224Tb\210\305\207\307\207" [reftex-allow-detached-macro-args bound (93 125) re-search-backward "[]}][ ]*[\n ]?\\([ ]*%[^\n ]*[\n ]\\)*[ ]*\\=" t 0 nil] 4 (#$ . 16769)]) (put 'reftex-move-to-previous-arg 'byte-optimizer 'byte-compile-inline-expand) #@53 Call `reftex-what-macro' with special syntax table. (defalias 'reftex-what-macro-safe #[(which &optional bound) "\305 \306\216\307 !\210\310\311\f\"+\207" [saved-syntax reftex-syntax-table case-fold-search which bound syntax-table #[nil "\301!\207" [saved-syntax set-syntax-table] 2] set-syntax-table nil reftex-what-macro] 3 (#$ . 17325)]) #@811 Find out if point is within the arguments of any TeX-macro. The return value is either ("\macro" . (point)) or a list of them. If WHICH is nil, immediately return nil. If WHICH is 1, return innermost enclosing macro. If WHICH is t, return list of all macros enclosing point. If WHICH is a list of macros, look only for those macros and return the name of the first macro in this list found to enclose point. If the optional BOUND is an integer, bound backwards directed searches to this point. If it is nil, limit to nearest \section - like statement. This function is pretty stable, but can be fooled if the text contains things like \macro{aa}{bb} where \macro is defined to take only one argument. As RefTeX cannot know this, the string "bb" would still be considered an argument of macro \macro. (defalias 'reftex-what-macro #[(which &optional bound) "\204 \306 \210\3072 \204 \310\307\311\"\210\n\206! \212\312\311\313#\210`)\311\211\211\211\211\211 \214\212e\n]d}\210\3141J \311!\315\316!\210)\3170\202N \210\202\203\313\320\nh\321>\206t \"\203s \312\322\n\317#\203s \320\224Tb\210\317\202t \311)\203\234 \3231\210 \311!\324 \210)\3170\202\212 \210\311\203\234 g\325=\203\226 \fT T\202U ` g\325U\204\253 g\326U\203\f\312\327\311\317#\203\f\330\320!\331\332!\203\306 \330\320! S\333#\"\211\203\340 \3348\206\331 \335V\203\340 \311\203\f \317=\203\367 `BB\202\f \313=\204 \235\203\f\310\307`B\"\210 b\210\2029 )\237.0\207" [reftex-section-regexp which bound entry cnt-opt cnt reftex-compile-variables exit throw nil re-search-backward 1 (error) up-list -1 t 0 (93 125) "[]}][ ]*[\n ]?\\([ ]*%[^\n ]*[\n ]\\)*[ ]*\\=" (error) backward-sexp 91 123 "\\\\[*a-zA-Z]+\\=" reftex-match-string looking-at "\\\\begin{[^}]*}" assoc 4 100 cmd cmd-list pos forward-sexp-function reftex-allow-detached-macro-args reftex-env-or-mac-alist] 7 (#$ . 17677)]) #@588 Find out if point is inside a LaTeX environment. The return value is (e.g.) either ("equation" . (point)) or a list of them. If WHICH is nil, immediately return nil. If WHICH is 1, return innermost enclosing environment. If WHICH is t, return list of all environments enclosing point. If WHICH is a list of environments, look only for those environments and return the name of the first environment in this list found to enclose point. If the optional BOUND is an integer, bound backwards directed searches to this point. If it is nil, limit to nearest \section - like statement. (defalias 'reftex-what-environment #[(which &optional bound) "\204 \306 \210\3072} \212 \204 \310\307\311\"\210\n\206\"