As with any macro you can just use:
#undef __LINE__
#undef __FILE__
and then you can redefine them.
You can also pass -U macroname
to undef a macro name and -D macroname=definition
to define a macro name to the gcc
options.
Note that, as indicated in another answer, undefining or redefining __LINE__
or __FILE__
in C invokes undefined behavior.