nicolas
nicolas

Reputation: 9815

trace who sets a variable 'yas-snippet-dirs' in elisp

Some elisp init function sets the variable 'yas-snippet-dirs' incorrectly.

Is there a way to have a debug mode, to get a log of all the stacktraces which end up modifying this value ?

Upvotes: 1

Views: 84

Answers (2)

Stefan
Stefan

Reputation: 28571

In a recent enough Emacs, you can use debug-watch for that:

M-x debug-watch RET yas-snippet-dirs RET

should do the trick. If you need to add the watcher early on (before you can enter interactive commands), then put

(debug-watch 'yas-snippet-dirs)

somewhere early in your ~/.emacs.

Upvotes: 1

wasamasa
wasamasa

Reputation: 320

There is no such thing, but you may find the elisp bug hunter useful.

Upvotes: 1

Related Questions