From 02063fc14e491e782b855108b801eb92167ab958 Mon Sep 17 00:00:00 2001 From: Stefan Huber Date: Tue, 15 Oct 2013 13:14:49 +0200 Subject: [PATCH] vim: reactivate all STL idents for prepending --- dotfiles/vim/.vimrc | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/dotfiles/vim/.vimrc b/dotfiles/vim/.vimrc index 8c716d4..a68602e 100644 --- a/dotfiles/vim/.vimrc +++ b/dotfiles/vim/.vimrc @@ -136,9 +136,9 @@ function PrependCppNamespaceToIdent(ns, id) " in the middle begin with a star. " If #include and // and /* and ^* and :: is not prepend: - execute ':%s_\(\(#include\|\/\/\|\/\*\|^\s*\*[^/]\).*\|::\)\@_' . a:ns . '::' . a:id . '_ge' + execute ':%s@\(\(#include\|\/\/\|\/\*\|^\s*\*[^/]\).*\|::\)\@@' . a:ns . '::' . a:id . '@ge' " If #include and // and :: is not prepend, but */ is, and no further /* or // are found - execute ':%s_\(\(#include\|\/\/\).*\)\@_' . a:ns . '::' . a:id . '_ge' + execute ':%s@\(\(#include\|\/\/\).*\)\@@' . a:ns . '::' . a:id . '@ge' endfunction @@ -155,7 +155,6 @@ function PrependSTLNamespace() let id = id +['queue', 'stack', 'priority_queue'] let id = id +['ostream', 'istream', 'sstream'] let id = id +['pair', 'string'] - let id = ['map'] for i in id call PrependCppNamespaceToIdent("std", i) -- 2.30.2