Function: mc/mark-next-like-this-symbol

mc/mark-next-like-this-symbol is an interactive and natively compiled function defined in mc-mark-more.el.

Signature

(mc/mark-next-like-this-symbol ARG)

Documentation

Find and mark the next part of the buffer matching the currently active region If no region is active, mark the symbol at the point and find the next match With negative ARG, delete the last one instead. With zero ARG, skip the last one and mark next.

Key Bindings

This command is not in any keymaps.

Source Code

;; Defined in /nix/store/5q7a78ihkz25lf4xmxaa9m7b2ym63m36-emacs-packages-deps/share/emacs/site-lisp/elpa/multiple-cursors-20260419.931/mc-mark-more.el
(defun mc/mark-next-like-this-symbol (arg)
  "Find and mark the next part of the buffer matching the currently active region
If no region is active, mark the symbol at the point and find the next match
With negative ARG, delete the last one instead.
With zero ARG, skip the last one and mark next."
  (interactive "p")
  (if (< arg 0)
      (let ((cursor (mc/furthest-cursor-after-point)))
        (if cursor
            (mc/remove-fake-cursor cursor)
          (error "No cursors to be unmarked")))
    (if (region-active-p)
        (mc/mark-more-like-this (= arg 0) 'forwards)
      (mc--select-thing-at-point 'symbol)
      (mc/mark-more-like-this (= arg 0) 'forwards)))
  (mc/maybe-multiple-cursors-mode))