On Wed, Sep 7, 2011 at 6:56 PM, David Chanters
<[email protected]> wrote:
> Hi,
>
> On 7 September 2011 04:44, Ben Fritz <[email protected]> wrote:
>> Here's a more complete script, but I haven't tested it either:
>>
>> nnoremap! <Ctrl-]> :call <SID>SmartTagSearch()<CR>
>
> Vim seemingly doesn't like this line. In adding your example and
> sourcing it in Vim, I see:
>
> Error detected while processing /tmp/foo.vim:
> line 1:
> E477: No ! allowed: nnoremap! <Ctrl-]> :call <SID>SmartTagSearch()<CR>
> line 17:
> E477: No ! allowed: nnoremap! <Ctrl-T> :call <SID>SmartTagReturn()<CR>
>
Oops, that's wrong. I copied and pasted the pseudocode as a starting
point and missed that.
Also Ctrl ought to be just C in these mappings.
> So I removed the "!" from the nnoremap command, and that got rid of
> those messages but then never calls SmartTag{Search,Return}() -- any
> ideas?
>
Probably because <Ctrl-]> is an invalid mapping, it should be <C-]>.
Sorry about that.
> Seemingly also, Vim doesn't like this line:
>
> let g:last_tag_file = []
>
> It seems to take exception to "[]" -- changing it to the empty string
> "", seems to work, but again, I'm clutching at straws knowing nothing
> about Vimscript.
>
This line should be fine, it assigns an empty List to g:last_tag_file.
I don't know how that could fail.
> For reference:
>
> VIM - Vi IMproved 7.3 (2010 Aug 15, compiled Aug 15 2011 10:46:03)
> Included patches: 1-280
> Modified by [email protected]
>
Can you include a few more lines, for the included features? E.g. mine is:
VIM - Vi IMproved 7.3 (2010 Aug 15, compiled Jul 4 2011 00:09:21)
Included patches: 1-237
Compiled by ben@LivingRoom
Huge version with GTK2 GUI. Features included (+) or not (-):
+arabic +autocmd +balloon_eval +browse ++builtin_terms +byte_offset
+cindent +clientserver +clipboard +cmdline_compl
+cmdline_hist +cmdline_info +comments +conceal +cryptv +cscope
+cursorbind +cursorshape +dialog_con_gui +diff +digraphs
+dnd -ebcdic +emacs_tags +eval +ex_extra +extra_search +farsi
+file_in_path +find_in_path +float +folding -footer +fork()
+gettext -hangul_input +iconv +insert_expand +jumplist +keymap
+langmap +libcall +linebreak +lispindent +listcmds +localmap
-lua +menu +mksession +modify_fname +mouse +mouseshape +mouse_dec
+mouse_gpm -mouse_jsbterm +mouse_netterm -mouse_sysmouse
+mouse_xterm +multi_byte +multi_lang -mzscheme +netbeans_intg
+path_extra +perl/dyn +persistent_undo +postscript +printer
+profile +python/dyn -python3 +quickfix +reltime +rightleft -ruby
+scrollbind +signs +smartindent -sniff +startuptime
+statusline -sun_workshop +syntax +tag_binary +tag_old_static
-tag_any_white -tcl +terminfo +termresponse +textobjects
+title +toolbar +user_commands +vertsplit +virtualedit +visual
+visualextra +viminfo +vreplace +wildignore +wildmenu
+windows +writebackup +X11 -xfontset +xim +xsmp_interact
+xterm_clipboard -xterm_save
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php