Function: js--re-search-forward-inner
js--re-search-forward-inner is a byte-compiled function defined in
js.el.gz.
Signature
(js--re-search-forward-inner REGEXP &optional BOUND COUNT)
Documentation
Helper function for js--re-search-forward.
Source Code
;; Defined in /usr/src/emacs/lisp/progmodes/js.el.gz
(defun js--re-search-forward-inner (regexp &optional bound count)
"Helper function for `js--re-search-forward'."
(let ((parse)
str-terminator
(orig-macro-end (save-excursion
(when (js--beginning-of-macro)
(c-end-of-macro)
(point)))))
(while (> count 0)
(re-search-forward regexp bound)
(setq parse (syntax-ppss))
(cond ((setq str-terminator (nth 3 parse))
(when (eq str-terminator t)
(setq str-terminator ?/))
(re-search-forward
(concat "\\([^\\]\\|^\\)" (string str-terminator))
(point-at-eol) t))
((nth 7 parse)
(forward-line))
((or (nth 4 parse)
(and (eq (char-before) ?\/) (eq (char-after) ?\*)))
(re-search-forward "\\*/"))
((and (not (and orig-macro-end
(<= (point) orig-macro-end)))
(js--beginning-of-macro))
(c-end-of-macro))
(t
(setq count (1- count))))))
(point))