branch: master
commit 812df519069555a7b670f6d300239092642aa02e
Merge: 87f43f3 e265b69
Author: Dmitry Gutov <[email protected]>
Commit: Dmitry Gutov <[email protected]>
Merge pull request #326 from phst/compiler-warning-25
Fix a byte compilation warning on Emacs 25
---
js2-mode.el | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/js2-mode.el b/js2-mode.el
index c999e48..292af25 100644
--- a/js2-mode.el
+++ b/js2-mode.el
@@ -12569,7 +12569,9 @@ it marks the next defun after the ones already marked."
(defun js2-jump-to-definition (&optional arg)
"Jump to the definition of an object's property, variable or function."
(interactive "P")
- (ring-insert find-tag-marker-ring (point-marker))
+ (if (eval-when-compile (fboundp 'xref-push-marker-stack))
+ (xref-push-marker-stack)
+ (ring-insert find-tag-marker-ring (point-marker)))
(js2-reparse)
(let* ((node (js2-node-at-point))
(parent (js2-node-parent node))