Hey folks,
I've written a program in C++ that takes an input filename as a command line parameter, and that filename gets passed to the processing function as a char*, then the processing function declares an ifstream and does it's work.
What I would like to do, is if no filename is given at the command line as an argument, then stdin is used for input. The problem is, what can I pass to the processing function as a parameter to tell it to use stdin? I assume I'd have to change the parameter type, but to what? I doubt I need to make another version of that function...
Anyone wanna give me a hint? Does this rambling even make sense?
Thanks,
~arker