Automatically prepend std:: to cout, etc. in Visual Studio for C++ and Eclipse -
edit: added "and eclipse" title , body pf question. need in both places.
i know "thou shalt not "using"" in c++ so...
how might add tool (enable existing tool) in ms visual studio 2008 (vc++) and/or eclipse juno allow me type cout
, press space bar, or maybe <
, have editor replace cout
std::cout
.
can extend std::
items?
can such tool recognize cout
in "code" space , not in "comment" space or "quoted string" space?
you can add using namespace std;
top of file, after #include
s, implicitly add std::
. text of code not change (that is, compiler won't go , textually pre-pend std::
everywhere) know in std
namespace symbols can't find elsewhere.