Hi,
I have a C++ project in DOT NET. I am using the __FILE__ and __LINE__
to print the current file and line number. I do not want the file anem
with the full path to be printed. So I used the #line directive.
[code]
#line 3 "11.cpp"
[/code]
Still the full file name along with the name (11.c) gets printed. If I
change 11.c above and type something else, say trial.cpp, the full file
path along with trial.cpp gets printed. How can I just get the file
name printed using __FILE__?
Regards,
AA
David Lowndes - 30 Nov 2006 07:42 GMT
> I have a C++ project in DOT NET. I am using the __FILE__ and __LINE__
>to print the current file and line number. I do not want the file anem
>with the full path to be printed.
Have a look at the /FC compiler switch.
Dave