Questions tagged [filetype-c++]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
9
votes
3answers
2k views

How do I add skeleton text to new vim files?

I use Vim for writing C++, and I have quite a few #include<> statements, comments, etc. that I must include in each new file I create. I've added autocmd BufNewFile *.cpp r C:\(full file path ...
13
votes
5answers
2k views

Quick search, limited to a C++ function

I work on a rather large C++ project. One of the more frustrating aspects of its organization is very large functions placed inside ridiculously large files. I often want to search for any instance ...
11
votes
3answers
963 views

Vim, ctags and overloading

Is there a way to make vim jump to the right matching definition automatically in case of multiple definitions. Our C++ code heavily uses function overloading and vim's handling of ctags does not ...
6
votes
2answers
3k views

Jumping to start/end of function definition in C++

Is there an easy way to jump to the beginning or end of the function your cursor is currently inside? It doesn't seem like sentence/paragraph/section have useful syntax aware meanings when editing C++....
17
votes
4answers
20k views

Can I jump to a function declaration or definition in a multiple C++ source files project?

Can I jump to a function declaration or definition in a multiple C++ source files project? Lets say I have a header file foo.hpp: int bar(); and a source file foo.cpp: #include "foo.hpp" int bar() ...
5
votes
1answer
764 views

Search and replace, but ignore text in quotes

As a poor-mans refactoring, I'd like to do a search and replace, but omit strings that are in double quotes (C/C++ quoting rules). For example cout << "Some variable " << variable <<...
5
votes
2answers
640 views

Vim `cpp` Syntax highlighter prematurely ends macros mid-word

NOTE: This question is a "manual migration" from here: https://superuser.com/q/875751/199803 My Vim syntax highlighter for ft=cpp is prematurely ending some macros mid-line. For example: (The ...