<br><br><div class="gmail_quote">On Wed, Apr 6, 2011 at 6:58 AM, York Zhao <span dir="ltr"><<a href="mailto:gtdplatform@gmail.com" target="_blank">gtdplatform@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Never mind, just registered a new user and I can edit the page now. I've corrected a typing mistake in the bug "<span style="color:rgb(105, 105, 105);font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:12px;line-height:18px"><a href="https://gitorious.org/vimpulse/pages/Bugs#bn+works,+but+bp+doesn't" style="color:rgb(237, 107, 43);text-decoration:none" target="_blank"><code style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;padding-top:0px;padding-right:0px;padding-bottom:0px;padding-left:0px;font-style:normal;font-weight:normal;font-size:12px;line-height:12px">bn</code> works, but <code style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;padding-top:0px;padding-right:0px;padding-bottom:0px;padding-left:0px;font-style:normal;font-weight:normal;font-size:12px;line-height:12px">bp</code> doesn’t</a>".</span><div>
<font color="#696969" face="'Helvetica Neue', Helvetica, Arial, sans-serif"><span style="font-size:12px;line-height:18px">By the way, I'm very new to emacs and lisp and couldn't find in the source code where the ex command ":bn" is being handled. Could anybody here give me some idea?</span></font></div>
<div><font color="#696969" face="'Helvetica Neue', Helvetica, Arial, sans-serif"><span style="font-size:12px;line-height:18px"></span></font></div></blockquote></div><br><div><br></div><div>Hey York,</div><div><br>
</div><div>The ex commands are stored in an association list (which is a key-value like data structure composed by a list of cells).</div><div><br></div><div>"bn" is an abbreviation for bnext. Run this:</div><div>
<div><br></div><div>(assoc "bnext" ex-token-alist)</div><div>;; ("bnext" "next")</div><div><br></div><div>So it's an alias... resolve again:</div><div><div><br></div></div></div><div><div>
(assoc "next" ex-token-alist)</div><div>;; ("next" (ex-next ex-cycle-other-window))</div></div><div><br></div><div>So when you run the command "bn", ex expands to "bnext", then "next", and finally evaluates the code (ex-next ex-cycle-other-window)</div>
<div><br></div><div>Tim</div>