I need the preprocessor to change a certain comment from the source files into normal code and keep registry of them:
Example: Let's say the comment is: //Check, and it's followed by any definition let's say we've got:
int main(){
//Checkint Time;
//Check char* name;
int age;
... More Code
}
So i need the preprocessor to take away those //Check, but also to keep a registry of the definitions for further serialization(put them into a .json file).
So the resulting source code before the compiling must be:
class test{
int Time;
char* name;
int age;
... More Code
}
And also the registry of the definitions to e serialized later.
So my question is, how can i make a pre-processor that takes the Idea away, write the definitions in the source file to be compiled, and to keep a registry of those definitions?.
PD: I'm using CLion in Linux.
