;ELC ;;; Compiled ;;; in Emacs version 28.0.50 ;;; with all optimizations. (byte-code "\300\301!\210\300\302!\210\300\303!\210\300\304!\207" [require cl-lib easymenu seq cider-eval] 2) (defconst cider-inspector-buffer "*cider-inspect*") (byte-code "\300\301\302\303\304\305\306\307\310\311& \210\312\313\314\315\316DD\317\320\321\306\301\310\322& \210\312\323\314\315\324DD\325\320\326\306\301\310\327& \210\312\330\314\315\331DD\332\320\333\306\301\310\334& \210\312\335\314\315\336DD\337\320\340\306\301\310\341& \210\312\342\314\315\343DD\344\320\340\306\301\310\345& \210\312\346\314\315\347DD\350\320\340\306\301\310\351& \207" [custom-declare-group cider-inspector nil "Presentation and behavior of the CIDER value inspector." :prefix "cider-inspector-" :group cider :package-version (cider . "0.10.0") custom-declare-variable cider-inspector-page-size funcall function #[0 "\300\207" [32] 1] "Default page size in paginated inspector view.\nThe page size can be also changed interactively within the inspector." :type (integer :tag "Page size" 32) (cider . "0.10.0") cider-inspector-max-atom-length #[0 "\300\207" [150] 1] "Default max length of nested atoms before they are truncated.\n'Atom' here means any collection member that satisfies (complement coll?).\nThe max length can be also changed interactively within the inspector." (integer :tag "Max atom length" 150) (cider . "1.1.0") cider-inspector-max-coll-size #[0 "\300\207" [5] 1] "Default number of nested collection members to display before truncating.\nThe max size can be also changed interactively within the inspector." (integer :tag "Max collection size" 5) (cider . "1.1.0") cider-inspector-fill-frame #[0 "\300\207" [nil] 1] "Controls whether the CIDER inspector window fills its frame." boolean (cider . "0.15.0") cider-inspector-skip-uninteresting #[0 "\300\207" [t] 1] "Controls whether to skip over uninteresting values in the inspector.\nOnly applies to navigation with `cider-inspector-prev-inspectable-object'\nand `cider-inspector-next-inspectable-object', values are still inspectable\nby clicking or navigating to them by other means." (cider . "0.25.0") cider-inspector-auto-select-buffer #[0 "\300\207" [t] 1] "Determines if the inspector buffer should be auto selected." (cider . "0.27.0")] 10) #@86 Regexp matching values which are not interesting to inspect and can be skipped over. (defvar cider-inspector-uninteresting-regexp (concat "nil\\|:" clojure--sym-regexp "\\|[+-.0-9]+") (#$ . 2298)) (defvar cider-inspector-mode-map (byte-code "\301 \302\"\210\303\304\305#\210\303\306\307#\210\303\310\311#\210\303\312\313#\210\303\314\315#\210\303\316\317#\210\303\320\315#\210\303\321\317#\210\303\322\317#\210\303\323\324#\210\303\325\326#\210\303\327\330#\210\303\331\332#\210\303\333\334#\210\303\335\334#\210\303\336\337#\210\303\340\337#\210\341\342!\210\343\344\345\346$\210\207" [cider-popup-buffer-mode-map make-sparse-keymap set-keymap-parent define-key " " cider-inspector-operate-on-point [mouse-1] cider-inspector-operate-on-click "l" cider-inspector-pop "g" cider-inspector-refresh [next] cider-inspector-next-page [prior] cider-inspector-prev-page " " [134217760] [33554464] "s" cider-inspector-set-page-size "a" cider-inspector-set-max-atom-length "c" cider-inspector-set-max-coll-size "d" cider-inspector-def-current-val [tab] cider-inspector-next-inspectable-object " " [(shift tab)] cider-inspector-previous-inspectable-object [backtab] (lambda (def-tmp-var) (defvar cider-inspector-mode-menu def-tmp-var #1="Menu for CIDER's inspector.")) nil easy-menu-do-define cider-inspector-mode-menu #1# ("CIDER Inspector" ["Inspect" cider-inspector-operate-on-point] ["Pop" cider-inspector-pop] ["Refresh" cider-inspector-refresh] "--" ["Next Inspectable Object" cider-inspector-next-inspectable-object] ["Previous Inspectable Object" cider-inspector-previous-inspectable-object] "--" ["Next Page" cider-inspector-next-page] ["Previous Page" cider-inspector-prev-page] ["Set Page Size" cider-inspector-set-page-size] ["Set Max Atom Length" cider-inspector-set-max-atom-length] ["Set Max Collection Size" cider-inspector-set-max-coll-size] ["Define Var" cider-inspector-def-current-val] "--" ["Quit" cider-popup-buffer-quit-function])] 6)) (defvar cider-inspector-mode-hook nil) (byte-code "\300\301N\204\f\302\300\301\303#\210\304\305!\204\302\305\306\307#\210\300\207" [cider-inspector-mode-hook variable-documentation put "Hook run after entering Inspector mode.\nNo problems result if this variable is not bound.\n`add-hook' automatically binds it. (This is true for all hook variables.)" boundp cider-inspector-mode-map definition-name cider-inspector-mode] 4) (defvar cider-inspector-mode-map (make-sparse-keymap)) (byte-code "\301\302N\204\303\301\302\304\305!#\210\306\307!\204\303\307\310\311#\210\312\313 !\210\307\302N\204-\303\307\302\304\314!#\210\306\300!\204B\303\300\310\311#\210\315\316\300\317\"\210!\210\300\302N\204P\303\300\302\304\320!#\210\303\311\321\322#\207" [cider-inspector-mode-abbrev-table cider-inspector-mode-map variable-documentation put purecopy "Keymap for `cider-inspector-mode'." boundp cider-inspector-mode-syntax-table definition-name cider-inspector-mode (lambda (def-tmp-var) (defvar cider-inspector-mode-syntax-table def-tmp-var)) make-syntax-table "Syntax table for `cider-inspector-mode'." (lambda (def-tmp-var) (defvar cider-inspector-mode-abbrev-table def-tmp-var)) define-abbrev-table nil "Abbrev table for `cider-inspector-mode'." derived-mode-parent special-mode] 5) #@263 Major mode for inspecting Clojure data structures. \{cider-inspector-mode-map} In addition to any hooks its parent mode `special-mode' might have run, this mode runs the hook `cider-inspector-mode-hook', as the final or penultimate step during initialization. (defalias 'cider-inspector-mode #[0 "\306\300!\210\307\310 \210\311\312\310\313N\203\314\311\313\310\313N#\210\315 !\204'\316 \317 \"\210\320\f!\211\2035\211\321 =\203;\322\f\323 \"\210\210\324 \325\"\204R !=\204R\326 \325!C#\210\327 !\210\330\f!\210 !\330\"!\210\306\331!\210\332\306\333!\210\334\335\336!\210)\337\340!\207" [delay-mode-hooks major-mode mode-name cider-inspector-mode-map cider-inspector-mode-syntax-table cider-inspector-mode-abbrev-table make-local-variable t special-mode cider-inspector-mode "Inspector" mode-class put keymap-parent set-keymap-parent current-local-map char-table-parent standard-syntax-table set-char-table-parent syntax-table abbrev-table-get :parents abbrev-table-put use-local-map set-syntax-table electric-indent-chars nil sesman-system CIDER visual-line-mode 1 run-mode-hooks cider-inspector-mode-hook local-abbrev-table clojure-mode-syntax-table] 5 (#$ . 5562) nil]) #@59 Inspect the result of the the expression preceding point. (defalias 'cider-inspect-last-sexp #[0 "\300\301 \302 \"\207" [cider-inspect-expr cider-last-sexp cider-current-ns] 3 (#$ . 6760) nil]) #@60 Inspect the result of the "top-level" expression at point. (defalias 'cider-inspect-defun-at-point #[0 "\300\301 \302 \"\207" [cider-inspect-expr cider-defun-at-point cider-current-ns] 3 (#$ . 6960) nil]) #@38 Inspect the most recent eval result. (defalias 'cider-inspect-last-result #[0 "\300\301\302 \"\207" [cider-inspect-expr "*1" cider-current-ns] 3 (#$ . 7171) nil]) #@219 Inspect the result of the preceding sexp. With a prefix argument ARG it inspects the result of the "top-level" form. With a second prefix argument it prompts for an expression to eval and inspect. (fn &optional ARG) (defalias 'cider-inspect #[256 "\211\300\267\202\301 \207\302 \207\303\304!\207\305\207" [#s(hash-table size 3 test eq rehash-size 1.5 rehash-threshold 0.8125 purecopy t data (1 6 4 9 16 12)) cider-inspect-last-sexp cider-inspect-defun-at-point call-interactively cider-inspect-expr nil] 3 (#$ . 7341) "p"]) #@182 A stack used to save point locations in inspector buffers. These locations are used to emulate `save-excursion' between `cider-inspector-push' and `cider-inspector-pop' operations. (defvar cider-inspector-location-stack nil (#$ . 7876)) #@193 A stack used to save point locations in inspector buffers. These locations are used to emulate `save-excursion' between `cider-inspector-next-page' and `cider-inspector-prev-page' operations. (defvar cider-inspector-page-location-stack nil (#$ . 8120)) #@290 Contains the value of the most recently used `cider-inspector-*' command. This is used as an alternative to the built-in `last-command'. Whenever we invoke any command through \[execute-extended-command] and its variants, the value of `last-command' is not set to the command it invokes. (defvar cider-inspector-last-command nil (#$ . 8380)) #@188 Contains the reference to the REPL where inspector was last invoked from. This is needed for internal inspector buffer operations (push, pop) to execute against the correct REPL session. (defvar cider-inspector--current-repl nil (#$ . 8730)) #@146 Evaluate EXPR in NS and inspect its value. Interactively, EXPR is read from the minibuffer, and NS the current buffer's namespace. (fn EXPR NS) (defalias 'cider-inspect-expr #[514 "\304 \305 \n %\211\205\306!\207" [cider-inspector--current-repl cider-inspector-page-size cider-inspector-max-atom-length cider-inspector-max-coll-size cider-current-repl cider-sync-request:inspect-expr cider-inspector--render-value] 8 (#$ . 8979) (byte-code "\300\301\302 \"\303 D\207" [cider-read-from-minibuffer "Inspect expression: " cider-sexp-at-point cider-current-ns] 3)]) #@133 Pop the last value off the inspector stack and render it. See `cider-sync-request:inspect-pop' and `cider-inspector--render-value'. (defalias 'cider-inspector-pop #[0 "\301\302 \211\205 \303!\207" [cider-inspector-last-command cider-inspector-pop cider-sync-request:inspect-pop cider-inspector--render-value] 3 (#$ . 9555) nil]) #@148 Inspect the value at IDX in the inspector stack and render it. See `cider-sync-request:inspect-push' and `cider-inspector--render-value' (fn IDX) (defalias 'cider-inspector-push #[257 "`B\301!\211\205\302!\210\303\304!\207" [cider-inspector-location-stack cider-sync-request:inspect-push cider-inspector--render-value cider-inspector-next-inspectable-object 1] 4 (#$ . 9894)]) #@119 Re-render the currently inspected value. See `cider-sync-request:inspect-refresh' and `cider-inspector--render-value' (defalias 'cider-inspector-refresh #[0 "\300 \211\205 \301!\207" [cider-sync-request:inspect-refresh cider-inspector--render-value] 3 (#$ . 10285) nil]) #@108 Jump to the next page when inspecting a paginated sequence/map. Does nothing if already on the last page. (defalias 'cider-inspector-next-page #[0 "`B\301 \211\205 \302!\207" [cider-inspector-page-location-stack cider-sync-request:inspect-next-page cider-inspector--render-value] 3 (#$ . 10565) nil]) #@112 Jump to the previous page when expecting a paginated sequence/map. Does nothing if already on the first page. (defalias 'cider-inspector-prev-page #[0 "\301\302 \211\205 \303!\207" [cider-inspector-last-command cider-inspector-prev-page cider-sync-request:inspect-prev-page cider-inspector--render-value] 3 (#$ . 10878) nil]) #@119 Set the page size in pagination mode to the specified PAGE-SIZE. Current page will be reset to zero. (fn PAGE-SIZE) (defalias 'cider-inspector-set-page-size #[257 "\300!\211\205\n\301!\207" [cider-sync-request:inspect-set-page-size cider-inspector--render-value] 4 (#$ . 11215) (byte-code "\301\302\"C\207" [cider-inspector-page-size read-number "Page size: "] 3)]) #@68 Set the max length of nested atoms to MAX-LENGTH. (fn MAX-LENGTH) (defalias 'cider-inspector-set-max-atom-length #[257 "\300!\211\205\n\301!\207" [cider-sync-request:inspect-set-max-atom-length cider-inspector--render-value] 4 (#$ . 11593) (byte-code "\301\302\"C\207" [cider-inspector-max-atom-length read-number "Max atom length: "] 3)]) #@102 Set the number of nested collection members to display before truncating to MAX-SIZE. (fn MAX-SIZE) (defalias 'cider-inspector-set-max-coll-size #[257 "\300!\211\205\n\301!\207" [cider-sync-request:inspect-set-max-coll-size cider-inspector--render-value] 4 (#$ . 11945) (byte-code "\301\302\"C\207" [cider-inspector-max-coll-size read-number "Max collection size: "] 3)]) #@160 Defines a var with VAR-NAME in current namespace. Doesn't modify current page. When called interactively NS defaults to current-namespace. (fn VAR-NAME NS) (defalias 'cider-inspector-def-current-val #[514 "\302 \303\"\211\205\304!\210\305\306 %\207" [cider-inspector--current-repl cider-eval-result-prefix cider-current-repl cider-sync-request:inspect-def-current-val cider-inspector--render-value message "%s#'%s/%s = %s"] 9 (#$ . 12329) (byte-code "\300 \301\302\303Q!D\207" [cider-current-ns read-from-minibuffer "Var name: " "/"] 5)]) #@43 Move one level up in the inspector stack. (defalias 'cider-sync-request:inspect-pop #[0 "\301\302\303\"\304\"\207" [cider-inspector--current-repl nrepl-dict-get cider-nrepl-send-sync-request ("op" "inspect-pop") "value"] 4 (#$ . 12889)]) #@54 Inspect the inside value specified by IDX. (fn IDX) (defalias 'cider-sync-request:inspect-push #[257 "\301\302\303\304\305F\"\306\"\207" [cider-inspector--current-repl nrepl-dict-get cider-nrepl-send-sync-request "op" "inspect-push" "idx" "value"] 7 (#$ . 13134)]) #@42 Re-render the currently inspected value. (defalias 'cider-sync-request:inspect-refresh #[0 "\301\302\303\"\304\"\207" [cider-inspector--current-repl nrepl-dict-get cider-nrepl-send-sync-request ("op" "inspect-refresh") "value"] 4 (#$ . 13408)]) #@53 Jump to the next page in paginated collection view. (defalias 'cider-sync-request:inspect-next-page #[0 "\301\302\303\"\304\"\207" [cider-inspector--current-repl nrepl-dict-get cider-nrepl-send-sync-request ("op" "inspect-next-page") "value"] 4 (#$ . 13660)]) #@57 Jump to the previous page in paginated collection view. (defalias 'cider-sync-request:inspect-prev-page #[0 "\301\302\303\"\304\"\207" [cider-inspector--current-repl nrepl-dict-get cider-nrepl-send-sync-request ("op" "inspect-prev-page") "value"] 4 (#$ . 13927)]) #@67 Set the page size in paginated view to PAGE-SIZE. (fn PAGE-SIZE) (defalias 'cider-sync-request:inspect-set-page-size #[257 "\301\302\303\304\305F\"\306\"\207" [cider-inspector--current-repl nrepl-dict-get cider-nrepl-send-sync-request "op" "inspect-set-page-size" "page-size" "value"] 7 (#$ . 14198)]) #@68 Set the max length of nested atoms to MAX-LENGTH. (fn MAX-LENGTH) (defalias 'cider-sync-request:inspect-set-max-atom-length #[257 "\301\302\303\304\305F\"\306\"\207" [cider-inspector--current-repl nrepl-dict-get cider-nrepl-send-sync-request "op" "inspect-set-max-atom-length" "max-atom-length" "value"] 7 (#$ . 14509)]) #@102 Set the number of nested collection members to display before truncating to MAX-SIZE. (fn MAX-SIZE) (defalias 'cider-sync-request:inspect-set-max-coll-size #[257 "\301\302\303\304\305F\"\306\"\207" [cider-inspector--current-repl nrepl-dict-get cider-nrepl-send-sync-request "op" "inspect-set-max-coll-size" "max-coll-size" "value"] 7 (#$ . 14840)]) #@87 Defines a var with VAR-NAME in NS with the current inspector value. (fn NS VAR-NAME) (defalias 'cider-sync-request:inspect-def-current-val #[514 "\301\302\303\304\305\306\257\"\307\"\207" [cider-inspector--current-repl nrepl-dict-get cider-nrepl-send-sync-request "op" "inspect-def-current-value" "ns" "var-name" "value"] 10 (#$ . 15198)]) #@292 Evaluate EXPR in context of NS and inspect its result. Set the page size in paginated view to PAGE-SIZE, maximum length of atomic collection members to MAX-ATOM-LENGTH, and maximum size of nested collections to MAX-COLL-SIZE if non nil. (fn EXPR NS PAGE-SIZE MAX-ATOM-LENGTH MAX-COLL-SIZE) (defalias 'cider-sync-request:inspect-expr #[1285 "\301\302\303\304\"\305\306\303 \205\307\nD \205\310\nD \205'\311\nD#BB\"\"\312\"\207" [cider-inspector--current-repl nrepl-dict-get cider-nrepl-send-sync-request append nrepl--eval-request "inspect" "true" "page-size" "max-atom-length" "max-coll-size" "value"] 16 (#$ . 15552)]) #@27 Render VALUE. (fn VALUE) (defalias 'cider-inspector--render-value #[257 "\306\307\310#\210\311\"\210\312 \"\210\n\203\313 \210rq\210 \314=\203.\315\f\203.\f\211A\242b\210 \316=\205@\315 \205@ \211A\242b)\207" [cider-inspector-buffer cider-inspector-auto-select-buffer cider-inspector-fill-frame cider-inspector-last-command cider-inspector-location-stack cider-inspector-page-location-stack cider-make-popup-buffer cider-inspector-mode ancillary cider-inspector-render cider-popup-buffer-display delete-other-windows cider-inspector-pop nil cider-inspector-prev-page] 5 (#$ . 16195)]) #@40 Render STR in BUFFER. (fn BUFFER STR) (defalias 'cider-inspector-render #[514 "rq\210\301 \210\302\3031\304\305!@!0\210\202\210\306\261\210)eb)\207" [inhibit-read-only cider-inspector-mode t (error) cider-inspector-render* read-from-string "\nInspector error for: "] 5 (#$ . 16802)]) #@33 Render ELEMENTS. (fn ELEMENTS) (defalias 'cider-inspector-render* #[257 "\211\211\205\211@\300!\210A\266\202\202\207" [cider-inspector-render-el*] 5 (#$ . 17102)]) #@21 Render EL. (fn EL) (defalias 'cider-inspector-render-el* #[257 "\2119\203\n\300!c\207\211;\203\301\302\303#c\207\211:\203%\211@\304=\203%\305c\207\211:\203;\211@\306=\203;\307A@AA@\"\207\310\311\"\207" [symbol-name propertize font-lock-face font-lock-keyword-face :newline "\n" :value cider-inspector-render-value message "Unrecognized inspector object: %s"] 5 (#$ . 17279)]) #@38 Render VALUE at IDX. (fn VALUE IDX) (defalias 'cider-inspector-render-value #[514 "`\300\301!!\302`\303\304\305F#\210\207" [cider-inspector-render-el* cider-font-lock-as-clojure add-text-properties cider-value-idx mouse-face highlight] 11 (#$ . 17674)]) #@327 Find the next/previous inspectable object. DIRECTION can be either 'next or 'prev. LIMIT is the maximum or minimum position in the current buffer. Return a list of two values: If an object could be found, the starting position of the found object and T is returned; otherwise LIMIT and NIL is returned. (fn DIRECTION LIMIT) (defalias 'cider-find-inspectable-object #[514 "\300\267\202\301\202\302\202\303\304\305#\205\306\306`\2045\211U\2045\307\306$\310\307\"\262\262\202\211\205;\311D\207" [#s(hash-table size 2 test eq rehash-size 1.5 rehash-threshold 0.8125 purecopy t data (next 6 prev 10)) next-single-property-change previous-single-property-change error "cl-ecase failed: %s, %s" (next prev) nil cider-value-idx get-text-property t] 10 (#$ . 17940)]) #@140 Move point to the next inspectable object. With optional ARG, move across that many objects. If ARG is negative, move backwards. (fn ARG) (defalias 'cider-inspector-next-inspectable-object #[257 "de\303\304V\203S\305\306\"\307!\210\310\311\"\310\304\"\203=\211b\210\2032 \312\313!)\262\204NS\262 \266\303\202\204Jb\266\312\202\314\315!\210\266\202\304W\205\252\305\316\"\307!\210\310\311\"\310\304\"\203\224\211U\204\224\211b\210\203\211 \312\313!)\262\204\245T\262 \266\303\202S\204\241b\266\312\202S\314\315!\210\266\202S\207" [cider-inspector-skip-uninteresting cider-inspector-uninteresting-regexp inhibit-changing-match-data nil 0 cider-find-inspectable-object next seqp seq--elt-safe 1 t looking-at error "No inspectable objects" prev] 12 (#$ . 18733) "p"]) #@143 Move point to the previous inspectable object. With optional ARG, move across that many objects. If ARG is negative, move forwards. (fn ARG) (defalias 'cider-inspector-previous-inspectable-object #[257 "\300[!\207" [cider-inspector-next-inspectable-object] 3 (#$ . 19567) "p"]) #@27 Return property at point. (defalias 'cider-inspector-property-at-point #[0 "\300\301\211`\"\206\211e`S]\"\207" [(cider-value-idx cider-range-button cider-action-number) #[514 "\300\211\211\211\211:\2035@\262\301\"\262\203'D\262\300\211\262\202(\302\2035A\262\300\262\202\207" [nil get-text-property t] 11 "\n\n(fn PROPERTIES POINT)"]] 6 (#$ . 19853)]) #@232 Invoke the command for the text at point. 1. If point is on a value then recursively call the inspector on that value. 2. If point is on an action then call that action. 3. If point is on a range-button fetch and insert the range. (defalias 'cider-inspector-operate-on-point #[0 "\300 \301!\210\302\303\"\302\304\"\211\305=\203\306!\207\307\310!\207" [cider-inspector-property-at-point seqp seq--elt-safe 1 0 cider-value-idx cider-inspector-push error "No object at point"] 7 (#$ . 20239) nil]) #@60 Move to EVENT's position and operate the part. (fn EVENT) (defalias 'cider-inspector-operate-on-click #[257 "\300\301!!\211\203\302\303\"\203\211b\210\304 \207\305\306!\207" [posn-point event-end get-text-property cider-value-idx cider-inspector-operate-on-point error "No clickable part here"] 5 (#$ . 20748) "@e"]) (provide 'cider-inspector)