Server IP : 111.118.215.189 / Your IP : 3.147.48.161 Web Server : Apache System : Linux md-in-83.webhostbox.net 4.19.286-203.ELK.el7.x86_64 #1 SMP Wed Jun 14 04:33:55 CDT 2023 x86_64 User : a1673wkz ( 2475) PHP Version : 8.2.25 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON Directory (0755) : /usr/share/emacs/24.3/lisp/emacs-lisp/ |
[ Home ] | [ C0mmand ] | [ Upload File ] |
---|
;ELC ;;; Compiled by mockbuild@buildfarm06-new.corp.cloudlinux.com on Fri Oct 11 10:09:04 2024 ;;; from file /builddir/build/BUILD/emacs-24.3/lisp/emacs-lisp/pcase.el ;;; in Emacs version 24.3.1 ;;; 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 'macroexp) (defconst pcase--memoize (make-hash-table :weakness 'key :test 'eq)) (defconst pcase--dontcare-upats '(t _ pcase--dontcare)) (byte-code "\300\301\302\303#\210\300\304\302\305#\207" [put pcase-UPAT edebug-form-spec (&or symbolp ("or" &rest pcase-UPAT) ("and" &rest pcase-UPAT) ("`" pcase-QPAT) ("guard" form) ("let" pcase-UPAT form) ("pred" &or lambda-expr (functionp &rest form) sexp) sexp) pcase-QPAT (&or ("," pcase-UPAT) (pcase-QPAT . pcase-QPAT) sexp)] 4) #@1645 Perform ML-style pattern matching on EXP. CASES is a list of elements of the form (UPATTERN CODE...). UPatterns can take the following forms: _ matches anything. SELFQUOTING matches itself. This includes keywords, numbers, and strings. SYMBOL matches anything and binds it to SYMBOL. (or UPAT...) matches if any of the patterns matches. (and UPAT...) matches if all the patterns match. `QPAT matches if the QPattern QPAT matches. (pred PRED) matches if PRED applied to the object returns non-nil. (guard BOOLEXP) matches if BOOLEXP evaluates to non-nil. (let UPAT EXP) matches if EXP matches UPAT. If a SYMBOL is used twice in the same pattern (i.e. the pattern is "non-linear"), then the second occurrence is turned into an `eq'uality test. QPatterns can take the following forms: (QPAT1 . QPAT2) matches if QPAT1 matches the car and QPAT2 the cdr. ,UPAT matches if the UPattern UPAT matches. STRING matches if the object is `equal' to STRING. ATOM matches if the object is `eq' to ATOM. QPatterns for vectors are not implemented yet. PRED can take the form FUNCTION in which case it gets called with one argument. (FUN ARG1 .. ARGN) in which case it gets called with an N+1'th argument which is the value being matched. A PRED of the form FUNCTION is equivalent to one of the form (FUNCTION). PRED patterns can refer to variables bound earlier in the pattern. E.g. you can match pairs where the cdr is larger than the car with a pattern like `(,a . ,(pred (< a))) or, with more checks: `(,(and a (pred numberp)) . ,(and (pred numberp) (pred (< a)))) (fn EXP &rest CASES) (defalias 'pcase '(macro . #[385 "\302@\"@\232\203 \211A@)\232\203 \211\211AA)\202: \211\203( \303\304!\210\305\"\306@BB#\210\211\262\207" [pcase--memoize x gethash message "pcase-memoize: equal first branch, yet different" pcase--expand puthash] 10 (#$ . 1041)])) (byte-code "\300\301\302\303#\210\300\301\304\305#\207" [put pcase lisp-indent-function 1 edebug-form-spec (form &rest (pcase-UPAT body))] 4) (defalias 'pcase--let* #[514 "\204 \301!\207\302\211@@)!\203 \303@C\304A\"\"\207\211A\262@\305\211A@)@\304\"D\306B\"\207" [x macroexp-progn pcase--trivial-upat-p macroexp-let* pcase--let* pcase--expand ((pcase--dontcare nil))] 10 "\n\n(fn BINDINGS BODY)"]) #@188 Like `let*' but where you can use `pcase' patterns for bindings. BODY should be an expression, and BINDINGS should be a list of bindings of the form (UPAT EXP). (fn BINDINGS &rest BODY) (defalias 'pcase-let* '(macro . #[385 "\301\"\211@\232\203 \211A\202 \302\"\303B#\210\211\262\207" [pcase--memoize gethash pcase--let* puthash] 8 (#$ . 3392)])) (byte-code "\300\301\302\303#\210\300\301\304\305#\207" [put pcase-let* lisp-indent-function 1 edebug-form-spec ((&rest (pcase-UPAT &optional form)) body)] 4) #@195 Like `let' but where you can use `pcase' patterns for bindings. BODY should be a list of expressions, and BINDINGS should be a list of bindings of the form (UPAT EXP). (fn BINDINGS &rest BODY) (defalias 'pcase-let '(macro . #[385 "A\204 \301BB\207\302\302\262\211\203Z \211@\211@>\203* \303\304!ABB\262\202S \305@!\2039 \211B\262\202S \303\306\307G\"!\211ABB\262@DB\262\210A\266\202\202 \210\310\237\301BBE\207" [pcase--dontcare-upats pcase-let* nil make-symbol "_" pcase--trivial-upat-p format "x%d" let] 9 (#$ . 3918)])) (byte-code "\300\301\302\303#\210\300\301\304\305#\207" [put pcase-let lisp-indent-function 1 edebug-form-spec pcase-let*] 4) (defalias 'pcase-dolist '(macro . #[385 "\300@!\203 \301BB\207\302\303!\301AB\304@DCBBE\207" [pcase--trivial-upat-p dolist make-symbol "x" pcase-let*] 8 "\n\n(fn SPEC &rest BODY)"])) (byte-code "\300\301\302\303#\210\300\301\304\305#\207" [put pcase-dolist lisp-indent-function 1 edebug-form-spec ((pcase-UPAT form) body)] 4) (defalias 'pcase--trivial-upat-p #[257 "\2119\205 \211>?\207" [pcase--dontcare-upats] 3 "\n\n(fn UPAT)"]) (defalias 'pcase--expand #[514 "\300!\203 \211\202 \301\302!\303C\303C\304\305\306\307\310\"\311\"\312\313%\303C\314\315\304\316\317\307\310 #\320\"\321\322% \"!\211\203] \211@\211@>\204V \211@\323=\204V \324\325@\"\210A\266\202\202<