]> git.eshelyaron.com Git - emacs.git/commitdiff
; Fix typos in symbol names
authorStefan Kangas <stefankangas@gmail.com>
Sun, 14 Jan 2024 13:56:06 +0000 (14:56 +0100)
committerEshel Yaron <me@eshelyaron.com>
Sat, 20 Jan 2024 16:28:52 +0000 (17:28 +0100)
(cherry picked from commit 725a3f32f8ba78ac5fffcd03be5b82cbc2c1b275)

14 files changed:
admin/cus-test.el
lisp/abbrev.el
lisp/calendar/todo-mode.el
lisp/jsonrpc.el
lisp/leim/quail/cyrillic.el
lisp/org/org-element.el
lisp/org/org-fold-core.el
lisp/org/org-macs.el
lisp/org/ox-latex.el
lisp/progmodes/eglot.el
lisp/term.el
lisp/term/pc-win.el
lisp/treesit.el
lisp/window.el

index 37ff4a7e9c5965db28a7d1aba24be1d6f1a22693..b86643a769a749ec7f75a297451b04def0660d6f 100644 (file)
@@ -146,7 +146,7 @@ Names should be as they appear in loaddefs.el.")
 
 (defvar cus-test-errors nil
   "List of problematic variables found by `cus-test-apropos'.
-Each element is (VARIABLE . PROBLEM); see `cus-test--format-problem'.")
+Each element is (VARIABLE . PROBLEM); see `cus-test--format-errors'.")
 
 (defvar cus-test-tested-variables nil
   "List of options tested by last call of `cus-test-apropos'.")
index 4e26136e8f841f2a5d0397d6a43375fdf391c1de..2bd9faad69dacd45cd53b3465d7506f064e0c5f4 100644 (file)
@@ -1275,7 +1275,7 @@ which see."
   (setq font-lock-multiline nil))
 
 (defun abbrev--possibly-save (query &optional arg)
-  "Hook function for use by `save-some-buffer-functions'.
+  "Hook function for use by `save-some-buffers-functions'.
 
 Maybe save abbrevs, and record whether we either saved them or asked to."
   ;; Query mode.
index 7989fff9466761e7983f046c93dd3a6a1fd456ed..d0b4c05cd68ed83528c543c02f9941afbc315a18 100644 (file)
@@ -1553,7 +1553,7 @@ the archive of the file moved to, creating it if it does not exist."
                 (prin1 todo-categories (current-buffer)))
              ;; If archive was just created, save it to avoid "File
              ;; <xyz> no longer exists!" message on invoking
-             ;; `todo-view-archived-items'.
+             ;; `todo-find-archive'.
              (unless (file-exists-p (buffer-file-name))
                (save-buffer))
              (todo-category-number (or new cat))
index 7ff57daeb7d4a23b5bd2cb57b130fa1b7d57120e..0ecde0a5425611bf7609740b7edde2a9934a542c 100644 (file)
@@ -691,6 +691,17 @@ With optional CLEANUP, kill any associated buffers."
 
 (cl-defun jsonrpc--process-filter (proc string)
   "Called when new data STRING has arrived for PROC."
+  (when jsonrpc--in-process-filter
+    ;; Problematic recursive process filters may happen if
+    ;; `jsonrpc-connection-receive', called by us, eventually calls
+    ;; client code which calls `process-send-string' (which see) to,
+    ;; say send a follow-up message.  If that happens to writes enough
+    ;; bytes for pending output to be received, we will lose JSONRPC
+    ;; messages.  In that case, remove recursiveness by re-scheduling
+    ;; ourselves to run from within a timer as soon as possible
+    ;; (bug#60088)
+    (run-at-time 0 nil #'jsonrpc--process-filter proc string)
+    (cl-return-from jsonrpc--process-filter))
   (when (buffer-live-p (process-buffer proc))
     (with-current-buffer (process-buffer proc)
       (let* ((conn (process-get proc 'jsonrpc-connection))
index 577898f82bdbf8855630c42f1d8e92f6c9889388..60c88221a6576cc677484ca744b96caa93fd8c5a 100644 (file)
@@ -1101,9 +1101,9 @@ as follows.
 ;; Ognyan Kulev <ogi@fmi.uni-sofia.bg> wrote:
 
 ;; I would suggest future `cyrillic-translit' to be with the
-;; modification of `cyrillic-translit-bulgarian' applied and the
+;; modification of `cyrillic-translit-bulgarian' (now deleted) applied and the
 ;; latter to disappear.  It could be used by people who write
-;; bulgarian e-mails with latin letters for kick start (phonetic input
+;; Bulgarian e-mails with latin letters for kick start (phonetic input
 ;; method is not so obvious as translit input method but each letter
 ;; is one keypress and a *lot* of people know it).
 
index 6e87e870996f6d15107f56729ed037ad059b4b19..ef96dc024d12c7f3bf9aee6cec858bb67e63d412 100644 (file)
@@ -6556,7 +6556,7 @@ the expected result."
                    (error "org-element: Parsing aborted by user.  Cache has been cleared.
 If you observe Emacs hangs frequently, please report this to Org mode mailing list (M-x org-submit-bug-report)."))
                  (message (substitute-command-keys
-                           "`org-element--parse-buffer': Suppressed `\\[keyboard-quit]'.  Press `\\[keyboard-quit]' %d more times to force interruption.")
+                           "`org-element--parse-to': Suppressed `\\[keyboard-quit]'.  Press `\\[keyboard-quit]' %d more times to force interruption.")
                           (- org-element--cache-interrupt-C-g-max-count
                              org-element--cache-interrupt-C-g-count)))
               (unless element
index 73b3c9bbf8cd439cad100a4c3511b58dff2a9c9d..be90ca398a1170526f63e59d6fb6a176ca59b8f4 100644 (file)
@@ -433,7 +433,7 @@ Return nil when there is no matching folding spec."
   (org-fold-core-get-folding-spec-from-alias spec-or-alias))
 
 (defsubst org-fold-core--check-spec (spec-or-alias)
-  "Throw an error if SPEC-OR-ALIAS is not in `org-fold-core--spec-priority-list'."
+  "Throw an error if SPEC-OR-ALIAS is not in `org-fold-core-folding-spec-list'."
   (unless (org-fold-core-folding-spec-p spec-or-alias)
     (error "%s is not a valid folding spec" spec-or-alias)))
 
index 5df6062e464c153611ead71abea7c9a566e3d125..2332c0c927c3a5bba3e749c36a2358f6ca0b37c6 100644 (file)
@@ -1072,7 +1072,7 @@ Return width in pixels when PIXELS is non-nil."
       ;; FIXME: Fallback to old limited version, because
       ;; `window-pixel-width' is buggy in older Emacs.
       (org--string-width-1 string)
-    ;; Wrap/line prefix will make `window-text-pizel-size' return too
+    ;; Wrap/line prefix will make `window-text-pixel-size' return too
     ;; large value including the prefix.
     (remove-text-properties 0 (length string)
                             '(wrap-prefix t line-prefix t)
index 3d260a32a2e8c94a590854cd0a353e4351849dae..834fb957329eb2e06bfeaafa6e73525b51440d50 100644 (file)
@@ -3667,7 +3667,7 @@ CONTENTS is the contents of the object."
 ;; takes care of tables with a "verbatim" mode.  Otherwise, it
 ;; delegates the job to either `org-latex--table.el-table',
 ;; `org-latex--org-table', `org-latex--math-table' or
-;; `org-latex--org-tabbing' functions,
+;; `org-latex--org-align-string-tabbing' functions,
 ;; depending of the type of the table and the mode requested.
 ;;
 ;; `org-latex--align-string' is a subroutine used to build alignment
index ba2cc72a6b49f8a3cc9e7a5fe7935ea4a52eef75..5d3f715916111baf293a16263926c0367c6e13be 100644 (file)
@@ -1797,6 +1797,55 @@ If optional MARKER, return a marker instead"
 
 \f
 ;;; More helpers
+(defconst eglot--uri-path-allowed-chars
+  (let ((vec (copy-sequence url-path-allowed-chars)))
+    (aset vec ?: nil) ;; see github#639
+    vec)
+  "Like `url-path-allowed-chars' but more restrictive.")
+
+(defun eglot--path-to-uri (path)
+  "URIfy PATH."
+  (let ((truepath (file-truename path)))
+    (if (and (url-type (url-generic-parse-url path))
+             ;; It might be MS Windows path which includes a drive
+             ;; letter that looks like a URL scheme (bug#59338)
+             (not (and (eq system-type 'windows-nt)
+                       (file-name-absolute-p truepath))))
+        ;; Path is already a URI, so forward it to the LSP server
+        ;; untouched.  The server should be able to handle it, since
+        ;; it provided this URI to clients in the first place.
+        path
+      (concat "file://"
+              ;; Add a leading "/" for local MS Windows-style paths.
+              (if (and (eq system-type 'windows-nt)
+                       (not (file-remote-p truepath)))
+                  "/")
+              (url-hexify-string
+               ;; Again watch out for trampy paths.
+               (directory-file-name (file-local-name truepath))
+               eglot--uri-path-allowed-chars)))))
+
+(declare-function w32-long-file-name "w32proc.c" (fn))
+(defun eglot--uri-to-path (uri)
+  "Convert URI to file path, helped by `eglot--current-server'."
+  (when (keywordp uri) (setq uri (substring (symbol-name uri) 1)))
+  (let* ((server (eglot-current-server))
+         (remote-prefix (and server (eglot--trampish-p server)))
+         (url (url-generic-parse-url uri)))
+    ;; Only parse file:// URIs, leave other URI untouched as
+    ;; `file-name-handler-alist' should know how to handle them
+    ;; (bug#58790).
+    (if (string= "file" (url-type url))
+        (let* ((retval (url-unhex-string (url-filename url)))
+               ;; Remove the leading "/" for local MS Windows-style paths.
+               (normalized (if (and (not remote-prefix)
+                                    (eq system-type 'windows-nt)
+                                    (cl-plusp (length retval)))
+                               (w32-long-file-name (substring retval 1))
+                             retval)))
+          (concat remote-prefix normalized))
+      uri)))
+
 (defun eglot--snippet-expansion-fn ()
   "Compute a function to expand snippets.
 Doubles as an indicator of snippet support."
index 1857c9ed9e3c2b8209b128ce6c625672e93cd868..2ce0c2b5e7993104848cc35a5b28c65d528af11c 100644 (file)
@@ -1109,7 +1109,7 @@ variable `term-input-autoexpand', and addition is controlled by the
 variable `term-input-ignoredups'.
 
 Input to, and output from, the subprocess can cause the window to scroll to
-the end of the buffer.  See variables `term-scroll-to-bottom-on-input',
+the end of the buffer.  See variables `term-scroll-snap-to-bottom',
 and `term-scroll-to-bottom-on-output'.
 
 If you accidentally suspend your process, use \\[term-continue-subjob]
index 02ad6b85c37e26b818fb0d078efdbd436995df26..92d65c75816e90100a3a536fe545be3334dd5cf5 100644 (file)
@@ -47,7 +47,7 @@
 
 ;; This was copied from etc/rgb.txt, except that some values were changed
 ;; a bit to make them consistent with DOS console colors, and the RGB
-;; values were scaled up to 16 bits, as `tty-define-color' requires.
+;; values were scaled up to 16 bits, as `tty-color-define' requires.
 ;;;
 ;; The mapping between the 16 standard EGA/VGA colors and X color names
 ;; was done by running a Unix version of Emacs inside an X client and a
index c8b473c7bb8ae5707b39368fc1fc10c5fd55636d..89f688b61c121ffeb01f78ef7436e89843c22874 100644 (file)
@@ -1665,7 +1665,7 @@ no-node
 
 comment-end
 
-    Matches if text after point matches `treesit-comment-end'.
+    Matches if text after point matches `comment-end-skip'.
 
 catch-all
 
index 1252e0a3db393eb81b19b313b719492cfd0150ef..62041d56280216470386ff262750e52662d325cb 100644 (file)
@@ -8625,7 +8625,7 @@ buffer.  ALIST is a buffer display action alist as compiled by
   canonical frame lines.  If it is the constant `full-height',
   prefer a full-height window.
 
-If ALIST contains a non-nil `inhibit-same--window' entry, do not
+If ALIST contains a non-nil `inhibit-same-window' entry, do not
 return the selected window."
   (let ((windows
          (window-list-1 nil 'nomini (cdr (assq 'lru-frames alist))))