views:

331

answers:

1

I have the following code in .vimrc

" to eliminate the effect of the line 1560 in taglist.vim 
if v:version >= 700
         nnoremap <buffer> <silent> t
                     \ 
         nnoremap <buffer> <silent> <C-t>
                     \                                                                                                                                                                                        
         endif

The command does what it should do. However, the command gives also me the following error at Vim's startup

No mapping found
No mapping found

How can you eliminate the keyboard shortcut, such that you do not get the message in Taglist but you can still use the default "T" for browsing up in Dvorak?

+1  A: 

Delete it. I don't use taglist, but the example you gave in your post does nothing. It is supposed to map something to something, but the right side is missing, i.e. something is supposed to being mapped to "t" and "C-t", but that something isn't defined.

Or, you can do this:

:silent nnoremap <buffer> <silent> t (and analoguous for the second line)

(mapping stays but the message will not be displayed)

ldigas
@Idigas: Your command does elinates the error message, but it also block T in TagList.
Masi
Well, don't do them both. If you do only ":silent ..." it should do nothing except repress the error message."
ldigas
Do you mean to have the following: "silent nnoremap <buffer> <silent> t" in .vimrc? It eliminates the keybinding and also the error, so it is not working.
Masi
@Masi - yes. What that does is supress the error message. Nothing else.But you have another problem. As I said, you are mapping something to nothing. A normal mapping of your type looks somethign like this, for example ":silent nnoremap <buffer> <silent> t :w<cr>" (for example, a mapping which will save the file when you press t". But your mapping is missing the right hand side - e.g. iz does nothing. Look at the mappings in your vimrc or somewhere and compare them to this one.
ldigas
I don't know what the supposed mapping is supposed to do, but it is not doing that because of these lines. If it is doing something, it is not because of these lines.
ldigas