Let's say this is a preprocessor definition before function f():
#define write std::cout << "test";
write
void f()
{
//...
}
and this is result of that macro:
std::cout << "test"
void f()
{
//...
}
How do I write that macro so it will skip function and also insert some code behind the function so that the result will be something like this:
std::cout << "test";
void f()
{
//...
}
std::cout << "test";
You know what I mean: a macro (or something else) that skips some code and inserts multiple lines.