Originally Posted by
sean
I'm not familiar with the C++ STL very well, but basically you want to split up everything separated by a ' ' (space) character or a ':' character. In C++ it knows that a token or term is separated by a space, or an operator, or someother syntactical mark. Just look through the documentation for a function with strings that "tokenizes" or "splits" strings. You'll need to specify the delimiting characters.
With C-style string you could easily just loop through this process:
Read until you find one of the delimiting characters, then create a string large enough for that token and copy it. Then the delimiting character would be the next token if it has any meaning, and you just loop through the process until you reach the end of the file. Then every meaningful part of your program is stored in memory - and you can process it syntactically as mentioned above.
edit: Moved to the C++ forum