unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* trouble writing small program
@ 2015-06-05 13:57 jenia mtl
  2015-06-05 17:38 ` Drew Adams
  0 siblings, 1 reply; 3+ messages in thread
From: jenia mtl @ 2015-06-05 13:57 UTC (permalink / raw)
  To: help-gnu-emacs

Hello:

Using evil and ggtags, I want to be able to jump back, using C-o, to the
position where I execute
ggtags-find-tag-dwim.
I have wrote this small program:

  (defun ggtags-go-to-definition ()
    (interactive)
    (let ((current-pos (make-marker)))
      (add-to-list 'evil-jump-list current-pos)
      (ggtags-find-tag-dwim (thing-at-point 'symbol))))

But it gives me the error "Marker does not point anywhere".

Can someone please tell me, how do I write this program correctly? That
is, I want to store the position before executing `ggtags...` and then
be able to jump back (using "C-o" a.k.a "evil-jump-back").

Thanks in advance for your kind help.
Jenia


^ permalink raw reply	[flat|nested] 3+ messages in thread
[parent not found: <mailman.4382.1433518067.904.help-gnu-emacs@gnu.org>]

end of thread, other threads:[~2015-06-05 17:38 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-06-05 13:57 trouble writing small program jenia mtl
2015-06-05 17:38 ` Drew Adams
     [not found] <mailman.4382.1433518067.904.help-gnu-emacs@gnu.org>
2015-06-05 15:35 ` Pascal J. Bourguignon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).