Merge from origin/emacs-29

3bdbb66efb ; CONTRIBUTE: Minor stylistic changes.
d0eb12e8d3 Fix typo in section 14.1 of Emacs Manual
b2fbec37f3 ; * etc/EGLOT-NEWS: Clarify scope of topmost section
131ec049db Eglot: unbreak eglot-extend-to-xref on w32
0622e1f29f Eglot: ensure server shutdown turns off eglot-inlay-hints...
59f66ea302 ; * lisp/emacs-lisp/package-vc.el: Remove completed item ...
d23dc3dd7e ; * lisp/emacs-lisp/package-vc.el (package-vc): Fix manua...
4508a024e8 ; Clarify documentation of 'cursor' text property
d2e82817a3 Add two typescript-ts-mode faces (bug#62429)
10918fc9d2 Fix scrolling window when point moves up
9b32bc134c Improve documentation of 'defcustom's :set keyword
ab4273056e Comp fix calls to redefined primtives with op-bytecode (b...
c98929c7e1 ; Fix last change
a14c3f62a6 ; Fix last change
09fece5722 Fix duplicate defcustom in eww.el
e45bd10a3d Fix indentation regression in 'C-h l'
46fd10a760 * doc/misc/tramp.texi (Remote shell setup): Clarify use o...
This commit is contained in:
João Távora 2023-04-03 00:33:03 +01:00
commit c108132d3b
16 changed files with 126 additions and 62 deletions

View file

@ -1764,27 +1764,32 @@ Return value is the fall-through block name."
(_ (signal 'native-ice
'("missing previous setimm while creating a switch")))))
(defun comp--func-arity (subr-name)
"Like `func-arity' but invariant against primitive redefinitions.
SUBR-NAME is the name of function."
(or (gethash subr-name comp-subr-arities-h)
(func-arity subr-name)))
(defun comp-emit-set-call-subr (subr-name sp-delta)
"Emit a call for SUBR-NAME.
SP-DELTA is the stack adjustment."
(let ((subr (symbol-function subr-name))
(nargs (1+ (- sp-delta))))
(let* ((arity (func-arity subr))
(minarg (car arity))
(maxarg (cdr arity)))
(when (eq maxarg 'unevalled)
(signal 'native-ice (list "subr contains unevalled args" subr-name)))
(if (eq maxarg 'many)
;; callref case.
(comp-emit-set-call (comp-callref subr-name nargs (comp-sp)))
;; Normal call.
(unless (and (>= maxarg nargs) (<= minarg nargs))
(signal 'native-ice
(list "incoherent stack adjustment" nargs maxarg minarg)))
(let* ((subr-name subr-name)
(slots (cl-loop for i from 0 below maxarg
collect (comp-slot-n (+ i (comp-sp))))))
(comp-emit-set-call (apply #'comp-call (cons subr-name slots))))))))
(let* ((nargs (1+ (- sp-delta)))
(arity (comp--func-arity subr-name))
(minarg (car arity))
(maxarg (cdr arity)))
(when (eq maxarg 'unevalled)
(signal 'native-ice (list "subr contains unevalled args" subr-name)))
(if (eq maxarg 'many)
;; callref case.
(comp-emit-set-call (comp-callref subr-name nargs (comp-sp)))
;; Normal call.
(unless (and (>= maxarg nargs) (<= minarg nargs))
(signal 'native-ice
(list "incoherent stack adjustment" nargs maxarg minarg)))
(let* ((subr-name subr-name)
(slots (cl-loop for i from 0 below maxarg
collect (comp-slot-n (+ i (comp-sp))))))
(comp-emit-set-call (apply #'comp-call (cons subr-name slots)))))))
(eval-when-compile
(defun comp-op-to-fun (x)

View file

@ -41,9 +41,6 @@
;; - Allow maintaining patches that are ported back onto regular
;; packages and maintained between versions.
;;
;; - Add a heuristic for guessing a `:lisp-dir' when cloning directly
;; from a URL.
;;; Code:
@ -58,7 +55,7 @@
(defgroup package-vc nil
"Manage packages from VC checkouts."
:group 'package
:link '(custom-manual "(emacs) Package from Source")
:link '(custom-manual "(emacs) Fetching Package Sources")
:prefix "package-vc-"
:version "29.1")