I know this should be posted to the vim mailing list, but I wasn’t able
subscribe to it, so I’m posting here instead.
I’ve been trying to write a vim script using vim’s ruby interface, but I
coming across weird errors in completely unexpected places. A very
example is the following: I give the following command (all in one line,
:ruby require ‘pathname’;
This command, which works perfectly when executed in irb or using ruby
from a ruby script, when called from vim gives an error:
SystemStackError: /usr/lib/ruby/1.8/pathname.rb:266:in `chop_basename’:
level too deep.
Moreover, these errors seem random: I can run a piece of code once and
works; i run it again later and it gives an error like the above one
always a SystemStackError). Yet, every time this happens, it’s always in
Does anyone know if there’s a reason for this behaviour, such as some
restriction to the ruby code you can call in ruby? Has anyone succeeded
using ruby interface? I’ve searched google, the vim mailing list and vim
documentation, but I found nothing.
Thanks in advance