C++ Identifier Not Found error -
i identifer not found error "startprocess":
int main(int argc, char* argv[]) { bool result=startprocess(argc, argv); return 0; } bool startprocess(int argc, char* argv[]) { }
but why?
functions need @ least declared before use them, if not defined. try putting @ top of file.
bool startprocess(int argc, char* argv[]);
the above declaration, you're telling compiler @ point, you're going provide definition function, this:
bool startprocess(int argc, char* argv[]) { code here... }
this difference between declaration , definition important being able separate code separate files. if had placed definition of startprocess
in different file, compiler never see while compiling file contains main
. however, declaration, you're making promise exists somewhere.
Comments
Post a Comment