commit e8790f42935762f34297400b09a00236b94ed6f0 (HEAD, refs/remotes/origin/master) Author: Philip Kaludercic Date: Sun Mar 26 13:50:27 2023 +0200 Have Xref inherit input method when reading identifiers * lisp/progmodes/xref.el (xref--read-identifier): Set INHERIT-INPUT-METHOD flag to non-nil. (Bug#61299) diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index 1ae60796601..d77024136d0 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -1525,7 +1525,7 @@ xref--read-identifier prompt)) (xref-backend-identifier-completion-table backend) nil nil nil - 'xref--read-identifier-history def))) + 'xref--read-identifier-history def t))) (if (equal id "") (or def (user-error "There is no default identifier")) id))) commit fca7e120d2bec5045aa42acbe2e027609dfe0a8d Author: Philip Kaludercic Date: Tue Mar 14 11:50:31 2023 +0100 Add option to register packages as projects * lisp/emacs-lisp/package-vc.el (package-vc-register-as-project): Add new option. (project-remember-projects-under): Declare function for usage in 'package-vc--clone'. (package-vc--clone): Respect 'package-vc-register-as-project'. * etc/NEWS: Document the feature. diff --git a/etc/NEWS b/etc/NEWS index 6c558553c58..9e45b1d80b2 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -245,6 +245,14 @@ following to your init file: (add-hook 'help-fns-describe-function-functions #'shortdoc-help-fns-examples-function) +** Package + +--- +*** New user option 'package-vc-register-as-project'. +When non-nil, it will automatically register every package as a +project, that you can quickly select using 'project-switch-project' +('C-x p p'). + * New Modes and Packages in Emacs 30.1 diff --git a/lisp/emacs-lisp/package-vc.el b/lisp/emacs-lisp/package-vc.el index 253b35f1f1a..ba3a75851ca 100644 --- a/lisp/emacs-lisp/package-vc.el +++ b/lisp/emacs-lisp/package-vc.el @@ -115,6 +115,11 @@ package-vc-default-backend vc-handled-backends)) :version "29.1") +(defcustom package-vc-register-as-project t + "Non-nil means that packages should be registered as projects." + :type 'boolean + :version "30.1") + (defvar package-vc-selected-packages) ; pacify byte-compiler ;;;###autoload @@ -559,6 +564,8 @@ package-vc--guess-backend (and url (alist-get url package-vc-heuristic-alist nil nil #'string-match-p))) +(declare-function project-remember-projects-under "project" (dir &optional recursive)) + (defun package-vc--clone (pkg-desc pkg-spec dir rev) "Clone the package PKG-DESC whose spec is PKG-SPEC into the directory DIR. REV specifies a specific revision to checkout. This overrides the `:branch' @@ -580,6 +587,11 @@ package-vc--clone (or (and (not (eq rev :last-release)) rev) branch)) (error "Failed to clone %s from %s" name url)))) + (when package-vc-register-as-project + (let ((default-directory dir)) + (require 'project) + (project-remember-projects-under dir))) + ;; Check out the latest release if requested (when (eq rev :last-release) (if-let ((release-rev (package-vc--release-rev pkg-desc))) commit 082870c0d7870ff5fd13d4c95f248b29f55cc393 Author: Michael Albinus Date: Sun Mar 26 20:47:25 2023 +0200 * test/infra/Dockerfile.emba (emacs-eglot): Adapt software selection. diff --git a/test/infra/Dockerfile.emba b/test/infra/Dockerfile.emba index 520fcb7e15e..163fc582e6f 100644 --- a/test/infra/Dockerfile.emba +++ b/test/infra/Dockerfile.emba @@ -64,7 +64,7 @@ FROM emacs-base as emacs-eglot RUN apt-get update && \ apt-get install -y --no-install-recommends -o=Dpkg::Use-Pty=0 \ - snapd wget \ + snapd wget lsb_release add-apt-repository gpg \ && rm -rf /var/lib/apt/lists/* # A recent clangd. It must be at least clangd 14, which is in Debian commit d0be0d541d3925b2f13cfb1a056046770829cef2 Author: Michael Albinus Date: Sun Mar 26 20:47:12 2023 +0200 Add sanity check in tramp-gvfs.el * lisp/net/tramp-gvfs.el (tramp-gvfs-listmountableinfo) (tramp-gvfs-listmounttypes): New defconst. (tramp-gvfs-maybe-open-connection): Add sanity check whether GVFS backend is available. diff --git a/lisp/net/tramp-gvfs.el b/lisp/net/tramp-gvfs.el index 0d23f5d88d5..c84f96d3c61 100644 --- a/lisp/net/tramp-gvfs.el +++ b/lisp/net/tramp-gvfs.el @@ -210,6 +210,20 @@ tramp-gvfs-methods-mounttracker tramp-gvfs-interface-mounttracker)) "The list of supported methods of the mount tracking interface.") +(defconst tramp-gvfs-listmountableinfo + (if (member "ListMountableInfo" tramp-gvfs-methods-mounttracker) + "ListMountableInfo" + "listMountableInfo") + "The name of the \"listMountableInfo\" method. +It has been changed in GVFS 1.14.") + +(defconst tramp-gvfs-listmounttypes + (if (member "ListMountTypes" tramp-gvfs-methods-mounttracker) + "ListMountTypes" + "listMountTypes") + "The name of the \"listMountTypes\" method. +It has been changed in GVFS 1.14.") + (defconst tramp-gvfs-listmounts (if (member "ListMounts" tramp-gvfs-methods-mounttracker) "ListMounts" @@ -233,6 +247,12 @@ tramp-gvfs-mountlocation-signature It has been changed in GVFS 1.14.") ;; +;; +;; +;; +;; +;; +;; ;; ;; ;; ;; +;; STRUCT mountable +;; STRING type +;; STRING scheme +;; ARRAY STRING scheme_aliases +;; INT32 default_port +;; BOOLEAN host_is_inet +;; ;; STRUCT mount_info ;; STRING dbus_id ;; OBJECT_PATH object_path @@ -2152,6 +2179,22 @@ tramp-gvfs-maybe-open-connection (unless (tramp-connectable-p vec) (throw 'non-essential 'non-essential)) + ;; Sanity check. + (let ((method (tramp-file-name-method vec))) + (unless (member + (or (rassoc method '(("smb" . "smb-share") + ("davs" . "dav") + ("nextcloud" . "dav") + ("afp". "afp-volume") + ("gdrive" . "google-drive"))) + method) + (with-tramp-dbus-call-method vec t + :session tramp-gvfs-service-daemon + tramp-gvfs-path-mounttracker + tramp-gvfs-interface-mounttracker + tramp-gvfs-listmounttypes)) + (tramp-error vec 'file-error "Method `%s' not supported by GVFS" method))) + ;; For password handling, we need a process bound to the connection ;; buffer. Therefore, we create a dummy process. Maybe there is a ;; better solution? commit b4a3be783aee05eaf0155354e71ca2ce1d5356e7 Author: Ken Brown Date: Sat Mar 25 18:59:33 2023 -0400 Implement list-system-processes on Cygwin * configure.ac (HAVE_PROCFS): Define to 1 on Cygwin. (Bug#62462) diff --git a/configure.ac b/configure.ac index c5300beb2ba..95701b55704 100644 --- a/configure.ac +++ b/configure.ac @@ -5621,7 +5621,7 @@ AC_DEFUN esac case $opsys in - gnu-* | solaris ) + gnu-* | solaris | cygwin ) dnl FIXME Can't we test if this exists (eg /proc/$$)? AC_DEFINE([HAVE_PROCFS], [1], [Define if you have the /proc filesystem.]) ;; commit 0770d7a0d084ffa3287b4232ef548f885d6fa4b4 Author: Phil Sainty Date: Mon Mar 27 01:19:19 2023 +1300 * lisp/term.el (term-mouse-paste) Do not treat as a yank command (bug#58608) This command sends the primary selection to the inferior process rather than inserting it into the buffer, and it's entirely up to the process as to whether anything at all gets inserted into the buffer as a result, so this is not a `yank' as far as Emacs is concerned. diff --git a/lisp/term.el b/lisp/term.el index 2e719567058..e1392908b90 100644 --- a/lisp/term.el +++ b/lisp/term.el @@ -1370,7 +1370,6 @@ term-mouse-paste (interactive "e") ;; Give temporary modes such as isearch a chance to turn off. (run-hooks 'mouse-leave-buffer-hook) - (setq this-command 'yank) (mouse-set-point click) ;; As we have moved point, bind `select-active-regions' to prevent ;; the `deactivate-mark' call in `term-send-raw-string' from commit e83df530cf715d3130e6f34f015d901527f79b5b Author: Phil Sainty Date: Mon Mar 27 01:06:52 2023 +1300 Fix primary selection modification during `term-mouse-paste' (bug#58608) * lisp/term.el (term-mouse-paste): Prevent the primary selection from being changed in the process of sending it to the inferior process. diff --git a/lisp/term.el b/lisp/term.el index 3e4907e8bfc..2e719567058 100644 --- a/lisp/term.el +++ b/lisp/term.el @@ -1372,7 +1372,13 @@ term-mouse-paste (run-hooks 'mouse-leave-buffer-hook) (setq this-command 'yank) (mouse-set-point click) - (term-send-raw-string (gui-get-primary-selection))) + ;; As we have moved point, bind `select-active-regions' to prevent + ;; the `deactivate-mark' call in `term-send-raw-string' from + ;; changing the primary selection (resulting in consecutive calls to + ;; `term-mouse-paste' each sending different text). (bug#58608). + ;; FIXME: Why does this command change point at all? + (let ((select-active-regions nil)) + (term-send-raw-string (gui-get-primary-selection)))) (defun term-paste () "Insert the last stretch of killed text at point." commit 1671e2db8a8d43da58c2f250c314a70aba199e09 Author: Evgeni Kolev Date: Wed Feb 8 17:16:02 2023 +0200 Fix 'go-ts-mode's incorrect docstring inserted for methods The docstring inserted with go-ts-mode's C-c C-d was incorrectly prefixed with the receiver "(myStruct).": // (myStruct).act func (m *myStruct) act () {...} The above docstring is not correct because the receiver "myStruct" should not be in the docstring. This commit fixes the incorrect behavior. * lisp/progmodes/go-ts-mode.el (go-ts-mode--defun-name): New optional argument SKIP-PREFIX. (go-ts-mode-docstring): Call (go-ts-mode--defun-name t) instead of (treesit-defun-name). (Bug#62371) diff --git a/lisp/progmodes/go-ts-mode.el b/lisp/progmodes/go-ts-mode.el index e6e8abd6445..fda6a36e42d 100644 --- a/lisp/progmodes/go-ts-mode.el +++ b/lisp/progmodes/go-ts-mode.el @@ -255,9 +255,10 @@ go-ts-mode (if (treesit-ready-p 'go) (add-to-list 'auto-mode-alist '("\\.go\\'" . go-ts-mode))) -(defun go-ts-mode--defun-name (node) +(defun go-ts-mode--defun-name (node &optional skip-prefix) "Return the defun name of NODE. -Return nil if there is no name or if NODE is not a defun node." +Return nil if there is no name or if NODE is not a defun node. +Methods are prefixed with the receiver name, unless SKIP-PREFIX is t." (pcase (treesit-node-type node) ("function_declaration" (treesit-node-text @@ -266,11 +267,10 @@ go-ts-mode--defun-name t)) ("method_declaration" (let* ((receiver-node (treesit-node-child-by-field-name node "receiver")) - (type-node (treesit-search-subtree receiver-node "type_identifier")) - (name-node (treesit-node-child-by-field-name node "name"))) - (concat - "(" (treesit-node-text type-node) ")." - (treesit-node-text name-node)))) + (receiver (treesit-node-text (treesit-search-subtree receiver-node "type_identifier"))) + (method (treesit-node-text (treesit-node-child-by-field-name node "name")))) + (if skip-prefix method + (concat "(" receiver ")." method)))) ("type_declaration" (treesit-node-text (treesit-node-child-by-field-name @@ -314,7 +314,7 @@ go-ts-mode-docstring ;; go to top comment line (while (go-ts-mode--comment-on-previous-line-p) (forward-line -1)) - (insert "// " (treesit-defun-name defun-node)) + (insert "// " (go-ts-mode--defun-name defun-node t)) (newline) (backward-char)))) commit 28db56d5f04879675aabb3fb2195ef2dd27716ba Author: Phil Sainty Date: Sun Aug 14 23:17:38 2022 +1200 * src/buffer.c (mode-line-format): Reorder and reformat %-construct docs The original formatting dates back to the earliest commits. It saved a few lines but was harder to follow. As windows are typically taller now than the terminals of the time, this reformatting now makes better sense for readabiity. See bug#57080. * doc/lispref/modes.texi: Order change for consistency. Add index. diff --git a/doc/lispref/modes.texi b/doc/lispref/modes.texi index 42e02b20fa3..18d5da5c7d1 100644 --- a/doc/lispref/modes.texi +++ b/doc/lispref/modes.texi @@ -2390,6 +2390,7 @@ Mode Line Variables @node %-Constructs @subsection @code{%}-Constructs in the Mode Line +@cindex @code{%}-constructs in the mode line Strings used as mode line constructs can use certain @code{%}-constructs to substitute various kinds of data. The @@ -2480,6 +2481,9 @@ %-Constructs @item %Z Like @samp{%z}, but including the end-of-line format. +@item %& +@samp{*} if the buffer is modified, and @samp{-} otherwise. + @item %* @samp{%} if the buffer is read only (see @code{buffer-read-only}); @* @samp{*} if the buffer is modified (see @code{buffer-modified-p}); @* @@ -2491,9 +2495,6 @@ %-Constructs @samp{-} otherwise. This differs from @samp{%*} only for a modified read-only buffer. @xref{Buffer Modification}. -@item %& -@samp{*} if the buffer is modified, and @samp{-} otherwise. - @item %@@ @samp{@@} if the buffer's @code{default-directory} (@pxref{File Name Expansion}) is on a remote machine, and @samp{-} otherwise. diff --git a/src/buffer.c b/src/buffer.c index 0c740775e5b..31c08cf3650 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -5124,35 +5124,38 @@ syms_of_buffer (void) negative) to the width specified by that number. A string is printed verbatim in the mode line except for %-constructs: - %b -- print buffer name. %f -- print visited file name. - %F -- print frame name. - %* -- print %, * or hyphen. %+ -- print *, % or hyphen. - %& is like %*, but ignore read-only-ness. - % means buffer is read-only and * means it is modified. - For a modified read-only buffer, %* gives % and %+ gives *. - %s -- print process status. %l -- print the current line number. + %b -- print buffer name. %c -- print the current column number (this makes editing slower). Columns are numbered starting from the left margin, and the leftmost column is displayed as zero. To make the column number update correctly in all cases, - `column-number-mode' must be non-nil. + `column-number-mode' must be non-nil. %C -- Like %c, but the leftmost column is displayed as one. + %e -- print error message about full memory. + %f -- print visited file name. + %F -- print frame name. %i -- print the size of the buffer. %I -- like %i, but use k, M, G, etc., to abbreviate. + %l -- print the current line number. + %n -- print Narrow if appropriate. %o -- print percent of window travel through buffer, or Top, Bot or All. %p -- print percent of buffer above top of window, or Top, Bot or All. %P -- print percent of buffer above bottom of window, perhaps plus Top, or print Bottom or All. %q -- print percent of buffer above both the top and the bottom of the window, separated by ‘-’, or ‘All’. - %n -- print Narrow if appropriate. + %s -- print process status. %z -- print mnemonics of keyboard, terminal, and buffer coding systems. %Z -- like %z, but including the end-of-line format. - %e -- print error message about full memory. - %@ -- print @ or hyphen. @ means that default-directory is on a - remote machine. - %[ -- print one [ for each recursive editing level. %] similar. - %% -- print %. %- -- print infinitely many dashes. + %& -- print * if the buffer is modified, otherwise hyphen. + %+ -- print *, % or hyphen (modified, read-only, neither). + %* -- print %, * or hyphen (read-only, modified, neither). + For a modified read-only buffer, %+ prints * and %* prints %. + %@ -- print @ if default-directory is on a remote machine, else hyphen. + %[ -- print one [ for each recursive editing level. + %] -- print one ] for each recursive editing level. + %- -- print enough dashes to fill the mode line. + %% -- print %. Decimal digits after the % specify field width to which to pad. */); DEFVAR_PER_BUFFER ("major-mode", &BVAR (current_buffer, major_mode), commit d4a3f64ad75444fa26f707aec5b642a900507a41 Author: Phil Sainty Date: Sun Aug 14 23:16:48 2022 +1200 * doc/lispref/modes.texi: Improve docs for obsolete '%m' construct Bug #57080. diff --git a/doc/lispref/modes.texi b/doc/lispref/modes.texi index 30baa7f4d80..42e02b20fa3 100644 --- a/doc/lispref/modes.texi +++ b/doc/lispref/modes.texi @@ -2515,13 +2515,16 @@ %-Constructs string in which @code{%}-constructs are allowed. @end table -The following @code{%}-construct is still supported, but it is -obsolete, since you can get the same result using the variable -@code{mode-name}. +@subsubheading Obsolete @code{%}-Constructs + + The following constructs should no longer be used. @table @code @item %m -The value of @code{mode-name}. +Obsolete; use the @code{mode-name} variable instead. The @code{%m} +construct is inadequate, as it produces an empty string if the value +of @code{mode-name} is a non-string mode-line construct (as in +@code{emacs-lisp-mode}, for example). @end table @node Properties in Mode commit 7466909df44e4030534988035da0c87b8126f79e Author: Phil Sainty Date: Sun Aug 14 23:14:51 2022 +1200 Improve docs for global-mode-string / %M construct * src/xdisp.c (global-mode-string): Update docstring. * doc/lispref/modes.texi: Update manual. diff --git a/doc/lispref/modes.texi b/doc/lispref/modes.texi index fff1ea65b07..30baa7f4d80 100644 --- a/doc/lispref/modes.texi +++ b/doc/lispref/modes.texi @@ -2349,18 +2349,19 @@ Mode Line Variables @defvar global-mode-string This variable holds a mode line construct that, by default, appears in -the mode line just after the @code{which-function-mode} minor mode if -set, else after @code{mode-line-modes}. Elements that are added to -this construct should normally end in a space (to ensure that -consecutive @code{global-mode-string} elements display properly). For -instance, the command @code{display-time} sets -@code{global-mode-string} to refer to the variable -@code{display-time-string}, which holds a string containing the time -and load information. +the mode line as part of @code{mode-line-misc-info}, just after the +@code{which-function-mode} information if that minor mode is enabled, +else after @code{mode-line-modes}. Elements that are added to this +construct should normally end in a space (to ensure that consecutive +@code{global-mode-string} elements display properly). For instance, +the command @code{display-time} sets @code{global-mode-string} to +refer to the variable @code{display-time-string}, which holds a string +containing the time and load information. The @samp{%M} construct substitutes the value of -@code{global-mode-string}, but that is obsolete, since the variable is -included in the mode line from @code{mode-line-format}. +@code{global-mode-string}. This construct is not used by the default +mode line, as the variable itself is used in +@code{mode-line-misc-info}. @end defvar Here is a simplified version of the default value of @@ -2440,6 +2441,10 @@ %-Constructs The current line number of point, counting within the accessible portion of the buffer. +@item %M +The value of @code{global-mode-string} (which is part of +@code{mode-line-misc-info} by default). + @item %n @samp{Narrow} when narrowing is in effect; nothing otherwise (see @code{narrow-to-region} in @ref{Narrowing}). diff --git a/src/xdisp.c b/src/xdisp.c index 7a4f683c973..754a7c16c76 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -36517,7 +36517,7 @@ syms_of_xdisp (void) Vinhibit_redisplay = Qnil; DEFVAR_LISP ("global-mode-string", Vglobal_mode_string, - doc: /* String (or mode line construct) included (normally) in `mode-line-format'. */); + doc: /* String (or mode line construct) included (normally) in `mode-line-misc-info'. */); Vglobal_mode_string = Qnil; DEFVAR_LISP ("overlay-arrow-position", Voverlay_arrow_position, commit 73f186b0c9345ca386bce7f441589c3530685fae Author: Phil Sainty Date: Sun Aug 14 23:11:43 2022 +1200 * src/buffer.c (mode-line-format): Document %o and %q constructs Missed from commit b0b02ca7f3e06d0f092df6f81babd1277bf93b0f. diff --git a/src/buffer.c b/src/buffer.c index 3bcd387f0c5..0c740775e5b 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -5139,9 +5139,12 @@ syms_of_buffer (void) %C -- Like %c, but the leftmost column is displayed as one. %i -- print the size of the buffer. %I -- like %i, but use k, M, G, etc., to abbreviate. + %o -- print percent of window travel through buffer, or Top, Bot or All. %p -- print percent of buffer above top of window, or Top, Bot or All. %P -- print percent of buffer above bottom of window, perhaps plus Top, or print Bottom or All. + %q -- print percent of buffer above both the top and the bottom of the + window, separated by ‘-’, or ‘All’. %n -- print Narrow if appropriate. %z -- print mnemonics of keyboard, terminal, and buffer coding systems. %Z -- like %z, but including the end-of-line format. commit 3e70b2213a4f3649639c41544f95ad35c1377755 Author: Phil Sainty Date: Sun Aug 14 22:34:41 2022 +1200 * src/buffer.c (mode-line-format): Remove docs for obsolete %t construct This documentation had been previously removed in 1999 in [1] but was subsequently restored again in a different form in 2006 in [2] as the construct was still supported on some systems. However it looks like it hasn't done what that documentation indicated since [3] in 2011, and the final remnant of this functionality was removed in [4] in 2013; so it seems clear that it's no longer supported and shouldn't be documented now. [1] commit 08de62001945d4dd32a3d6af44da05804cb296d5 [2] commit dafbe726b89a36010f3f24bb1efe4ace0a5f7f0f [3] commit 05c652517317d10690aaf0a6aa0bc876382b9d82 [4] commit 8549f9e89bd9288c4c709d183a5bf8f07dbeed3d diff --git a/src/buffer.c b/src/buffer.c index df1f5206668..3bcd387f0c5 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -5143,7 +5143,6 @@ syms_of_buffer (void) %P -- print percent of buffer above bottom of window, perhaps plus Top, or print Bottom or All. %n -- print Narrow if appropriate. - %t -- visited file is text or binary (if OS supports this distinction). %z -- print mnemonics of keyboard, terminal, and buffer coding systems. %Z -- like %z, but including the end-of-line format. %e -- print error message about full memory. commit 0724c6dbdaef2c549409836ba4f7999e05aa31fe Author: Mattias Engdegård Date: Sun Mar 26 12:09:41 2023 +0200 Use string-search instead of string-match[-p] when possible * lisp/progmodes/c-ts-mode.el (c-ts-mode--standalone-parent-skip-preproc): * lisp/progmodes/ruby-ts-mode.el (ruby-ts--align-chain): * lisp/treesit.el (treesit-max-buffer-size) (treesit--check-manual-coverage): Use the much faster string-search when just searching for a substring. diff --git a/lisp/progmodes/c-ts-mode.el b/lisp/progmodes/c-ts-mode.el index 59eb9fc23e6..d773b4a41f4 100644 --- a/lisp/progmodes/c-ts-mode.el +++ b/lisp/progmodes/c-ts-mode.el @@ -322,7 +322,7 @@ c-ts-mode--standalone-parent-skip-preproc ;; nil. parent (lambda (node) (and node - (not (string-match "preproc" (treesit-node-type node))) + (not (string-search "preproc" (treesit-node-type node))) (progn (goto-char (treesit-node-start node)) (looking-back (rx bol (* whitespace)) diff --git a/lisp/progmodes/ruby-ts-mode.el b/lisp/progmodes/ruby-ts-mode.el index d077c43ba52..d1034d467ab 100644 --- a/lisp/progmodes/ruby-ts-mode.el +++ b/lisp/progmodes/ruby-ts-mode.el @@ -469,7 +469,7 @@ ruby-ts--align-chain (let* (first-call ) (while (and parent (setq first-call (treesit-node-parent parent)) - (string-match-p "call" (treesit-node-type first-call))) + (string-search "call" (treesit-node-type first-call))) (setq parent first-call)) (treesit-node-start (treesit-search-subtree parent "\\." nil t)))) diff --git a/lisp/treesit.el b/lisp/treesit.el index 367d2c66ac7..2b0eca7f5c2 100644 --- a/lisp/treesit.el +++ b/lisp/treesit.el @@ -106,7 +106,7 @@ treesit-max-buffer-size ;; 40MB for 64-bit systems, 15 for 32-bit. (if (or (< most-positive-fixnum (* 2.0 1024 mb)) ;; 32-bit system with wide ints. - (string-match-p "--with-wide-int" system-configuration-options)) + (string-search "--with-wide-int" system-configuration-options)) (* 15 mb) (* 40 mb))) "Maximum buffer size (in bytes) for enabling tree-sitter parsing. @@ -3090,7 +3090,7 @@ treesit--check-manual-coverage (with-temp-buffer (insert-file-contents (find-library-name "treesit")) (cl-remove-if - (lambda (name) (string-match "treesit--" name)) + (lambda (name) (string-search "treesit--" name)) (cl-sort (save-excursion (goto-char (point-min))