LFPragma v1.0
Welcome to LFPragma, a very simple
preprocessor macro to extend the usefulness of "#pragma message". It defines a macro which can be used
to automatically include the filename and line number thus allowing you to double click on it in the output window in VC and be brought to the place where it is (just like the way compiler or linker warnings or errors work). You can use this for example to remind yourself to revisit source code etc etc.
Usage
- To use the class in your code simply include
lfpragma.h in your project and #include it in which ever of your modules needs to
make calls to the classes.
- To include the file and line
numbers in your #pragma messages just use it as follows:
#pragma message(INCLUDE_FILE_AND_LINE("Never play with matches"))
When you compile the module which includes this you will end up with an
output window in VC which will allow you to click on the line that says
"Never play with matches" and will bring you to the line where the
#pragma message is located.
- To see the class in action, have a look at the code in InitInstance
in the module "app.cpp".
History
V1.0 (9 August 2001)
CONTACTING
THE AUTHOR
PJ Naughter
Email: pjna@naughter.com
Web: http://www.naughter.com
9 August 2001