Current File : //proc/thread-self/root/kunden/usr/share/emacs/27.2/lisp/emacs-lisp/avl-tree.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 'generator)
#@67 compiler-macro for inlining `avl-tree-p'.
(fn CL-WHOLE-ARG CL-X)
(defalias 'avl-tree-p--cmacro #[514 "\300\301\302\303\211\211&\207" [cl--defsubst-expand (cl-x) (cl-block avl-tree-p (and (memq (type-of cl-x) cl-struct-avl-tree--tags) t)) nil] 9 (#$ . 429)])
(put 'avl-tree-p 'compiler-macro 'avl-tree-p--cmacro)
#@13
(fn CL-X)
(defalias 'avl-tree-p #[257 "\301!>\205 \302\207" [cl-struct-avl-tree--tags type-of t] 3 (#$ . 751)])
(byte-code "\300\301\302\303#\304\305\306\301#\207" [function-put avl-tree-p side-effect-free error-free put avl-tree- cl-deftype-satisfies] 5)
#@76 compiler-macro for inlining `avl-tree--dummyroot'.
(fn CL-WHOLE-ARG CL-X)
(defalias 'avl-tree--dummyroot--cmacro #[514 "\300\301\302\303\211\211&\207" [cl--defsubst-expand (cl-x) (cl-block avl-tree--dummyroot (progn (or (avl-tree-p cl-x) (signal 'wrong-type-argument (list 'avl-tree- cl-x))) (aref cl-x 1))) nil] 9 (#$ . 1018)])
(put 'avl-tree--dummyroot 'compiler-macro 'avl-tree--dummyroot--cmacro)
#@64 Access slot "dummyroot" of `avl-tree-' struct CL-X.
(fn CL-X)
(defalias 'avl-tree--dummyroot #[257 "\301!>\204 \302\303\304D\"\210\211\305H\207" [cl-struct-avl-tree--tags type-of signal wrong-type-argument avl-tree- 1] 5 (#$ . 1429)])
(byte-code "\300\301\302\303#\300\207" [function-put avl-tree--dummyroot side-effect-free t] 4)
#@73 compiler-macro for inlining `avl-tree--cmpfun'.
(fn CL-WHOLE-ARG CL-X)
(defalias 'avl-tree--cmpfun--cmacro #[514 "\300\301\302\303\211\211&\207" [cl--defsubst-expand (cl-x) (cl-block avl-tree--cmpfun (progn (or (avl-tree-p cl-x) (signal 'wrong-type-argument (list 'avl-tree- cl-x))) (aref cl-x 2))) nil] 9 (#$ . 1771)])
(put 'avl-tree--cmpfun 'compiler-macro 'avl-tree--cmpfun--cmacro)
#@61 Access slot "cmpfun" of `avl-tree-' struct CL-X.
(fn CL-X)
(defalias 'avl-tree--cmpfun #[257 "\301!>\204 \302\303\304D\"\210\211\305H\207" [cl-struct-avl-tree--tags type-of signal wrong-type-argument avl-tree- 2] 5 (#$ . 2167)])
(byte-code "\300\301\302\303#\300\207" [function-put avl-tree--cmpfun side-effect-free t] 4)
#@75 compiler-macro for inlining `avl-tree--create'.
(fn CL-WHOLE-ARG CMPFUN)
(defalias 'avl-tree--create--cmacro #[514 "\300\301\302\303\211\211&\207" [cl--defsubst-expand (cmpfun) (cl-block avl-tree--create (record 'avl-tree- (avl-tree--node-create nil nil nil 0) cmpfun)) nil] 9 (#$ . 2500)])
(put 'avl-tree--create 'compiler-macro 'avl-tree--create--cmacro)
#@59 Constructor for objects of type `avl-tree-'.
(fn CMPFUN)
(defalias 'avl-tree--create #[257 "\300\301\302\303\211\211\304$#\207" [record avl-tree- avl-tree--node-create nil 0] 8 (#$ . 2867)])
(cl-struct-define 'avl-tree- nil 'cl-structure-object 'record nil '((cl-tag-slot) (dummyroot (avl-tree--node-create nil nil nil 0)) (cmpfun)) 'cl-struct-avl-tree--tags 'avl-tree- t)
#@13
(fn TREE)
(defalias 'avl-tree--root '(macro . #[257 "\300\301DD\207" [avl-tree--node-left avl-tree--dummyroot] 4 (#$ . 3248)]))
#@76 compiler-macro for inlining `avl-tree--node-left'.
(fn CL-WHOLE-ARG CL-X)
(defalias 'avl-tree--node-left--cmacro #[514 "\300\301\302\303\211\211&\207" [cl--defsubst-expand (cl-x) (cl-block avl-tree--node-left (progn (aref cl-x 0))) nil] 9 (#$ . 3385)])
(put 'avl-tree--node-left 'compiler-macro 'avl-tree--node-left--cmacro)
#@64 Access slot "left" of `avl-tree--node' struct CL-X.
(fn CL-X)
(defalias 'avl-tree--node-left #[257 "\211\300H\207" [0] 3 (#$ . 3720)])
(byte-code "\300\301\302\303#\300\207" [function-put avl-tree--node-left side-effect-free t] 4)
#@77 compiler-macro for inlining `avl-tree--node-right'.
(fn CL-WHOLE-ARG CL-X)
(defalias 'avl-tree--node-right--cmacro #[514 "\300\301\302\303\211\211&\207" [cl--defsubst-expand (cl-x) (cl-block avl-tree--node-right (progn (aref cl-x 1))) nil] 9 (#$ . 3958)])
(put 'avl-tree--node-right 'compiler-macro 'avl-tree--node-right--cmacro)
#@65 Access slot "right" of `avl-tree--node' struct CL-X.
(fn CL-X)
(defalias 'avl-tree--node-right #[257 "\211\300H\207" [1] 3 (#$ . 4298)])
(byte-code "\300\301\302\303#\300\207" [function-put avl-tree--node-right side-effect-free t] 4)
#@76 compiler-macro for inlining `avl-tree--node-data'.
(fn CL-WHOLE-ARG CL-X)
(defalias 'avl-tree--node-data--cmacro #[514 "\300\301\302\303\211\211&\207" [cl--defsubst-expand (cl-x) (cl-block avl-tree--node-data (progn (aref cl-x 2))) nil] 9 (#$ . 4539)])
(put 'avl-tree--node-data 'compiler-macro 'avl-tree--node-data--cmacro)
#@64 Access slot "data" of `avl-tree--node' struct CL-X.
(fn CL-X)
(defalias 'avl-tree--node-data #[257 "\211\300H\207" [2] 3 (#$ . 4874)])
(byte-code "\300\301\302\303#\300\207" [function-put avl-tree--node-data side-effect-free t] 4)
#@79 compiler-macro for inlining `avl-tree--node-balance'.
(fn CL-WHOLE-ARG CL-X)
(defalias 'avl-tree--node-balance--cmacro #[514 "\300\301\302\303\211\211&\207" [cl--defsubst-expand (cl-x) (cl-block avl-tree--node-balance (progn (aref cl-x 3))) nil] 9 (#$ . 5112)])
(put 'avl-tree--node-balance 'compiler-macro 'avl-tree--node-balance--cmacro)
#@67 Access slot "balance" of `avl-tree--node' struct CL-X.
(fn CL-X)
(defalias 'avl-tree--node-balance #[257 "\211\300H\207" [3] 3 (#$ . 5462)])
(byte-code "\300\301\302\303#\300\207" [function-put avl-tree--node-balance side-effect-free t] 4)
#@97 compiler-macro for inlining `avl-tree--node-create'.
(fn CL-WHOLE-ARG LEFT RIGHT DATA BALANCE)
(defalias 'avl-tree--node-create--cmacro #[1285 "\300\301\302\303\211\211 & \207" [cl--defsubst-expand (left right data balance) (cl-block avl-tree--node-create (vector left right data balance)) nil] 15 (#$ . 5709)])
(put 'avl-tree--node-create 'compiler-macro 'avl-tree--node-create--cmacro)
#@81 Constructor for objects of type `avl-tree--node'.
(fn LEFT RIGHT DATA BALANCE)
(defalias 'avl-tree--node-create #[1028 "\300$\207" [vector] 9 (#$ . 6111)])
(byte-code "\300\301\302\303#\304\305\306\211\307\306\310\311\305\306& \210\312\313\314\315#\210\300\313\316\317#\306\207" [function-put avl-tree--node-create side-effect-free t cl-struct-define avl-tree--node nil vector ((left) (right) (data) (balance)) cl-struct-avl-tree--node-tags defalias avl-tree--node-branch aref "Get value of a branch of a node.\nNODE is the node, and BRANCH is the branch.\n0 for left pointer, 1 for right pointer and 2 for the data.\n\n(fn BRANCH NODE)" gv-expander #[385 "\300\301\302$\207" [gv--defsetter avl-tree--node-branch #[385 "\300\301C\"B\207" [aset append] 6 "\n\n(fn VAL &rest ARGS)"]] 7 "\n\n(fn DO &rest ARGS)"]] 11)
#@67 Return opposite direction to DIR (0 = left, 1 = right).
(fn DIR)
(defalias 'avl-tree--switch-dir '(macro . #[257 "\300\301E\207" [- 1] 4 (#$ . 6941)]))
#@59 Convert direction (0,1) to sign factor (-1,+1).
(fn DIR)
(defalias 'avl-tree--dir-to-sign '(macro . #[257 "\300\301\302ED\207" [1- * 2] 5 (#$ . 7101)]))
#@59 Convert sign factor (-x,+x) to direction (0,1).
(fn DIR)
(defalias 'avl-tree--sign-to-dir '(macro . #[257 "\300\301\302BB\303BB\207" [if < (0) (0 1)] 5 (#$ . 7262)]))
#@238 Rebalance a tree after deleting a node.
The deletion was done from the left (DIR=0) or right (DIR=1) sub-tree
of the left (BRANCH=0) or right (BRANCH=1) child of NODE.
Return t if the height of the tree has shrunk.
(fn NODE BRANCH DIR)
(defalias 'avl-tree--del-balance #[771 "\300\"\301Z\302_S\303\211\211\211\304H_\305V\203&