# A macro problem

I start to play with macros in texmacs. I encounter a problem:

I have this macro defined

<assign|demo|<macro|w|x|y|z|R<rsub|<arg|w> <arg|x> <arg|y> <arg|z>>>>

which basically assign \demo to the math R_{i j k l} with i,j,k and l being inserted by me when macro expands.

I want to have a shortcut to move from one parameter to the next parameter, so I defined the following:

(kbd-map
(:mode in-math?)
("C-h"
(let ((t (focus-tree)))
(if
(and (tree-in? t '(demo))
(not (tree-at-end? t)))
(traverse-next)
(set-message "Tree is end" "Tree is end")))))

I noticed that when I moved to the second argument using C-h key, it already displays an “Tree is end” message.

This may be a bug!