Function: sqlind-search-backward

sqlind-search-backward is a natively compiled function defined in sql-indent.el.

Signature

(sqlind-search-backward START REGEXP LIMIT)

Documentation

Search for REGEXP from START backward until LIMIT.

Finds a match that is not inside a comment or string, moves point to the match and returns it. If no match is found, point is moved to LIMIT and nil is returned.

Source Code

;; Defined in /nix/store/jxjf2h9nnkdqnn1w1mr0ag8bqng2rlrs-emacs-packages-deps/share/emacs/site-lisp/elpa/sql-indent-1.7/sql-indent.el
(defun sqlind-search-backward (start regexp limit)
  "Search for REGEXP from START backward until LIMIT.
Finds a match that is not inside a comment or string, moves point
to the match and returns it.  If no match is found, point is moved
to LIMIT and nil is returned."
  (goto-char start)
  (let ((done nil))
    (while (and (not done)
                (re-search-backward regexp limit 'noerror))
      (when (sqlind-same-level-statement (point) start)
        (setq done (point))))
    done))