And a quick description of how it works. The main body of the program reads the named file into a vector of strings.

It does this by allocating a buffer and reading the file into it until it runs out of file. For each buffer of data that it reads from the file, it looks through for line-breaks, using memchr.

Because the buffer might not finish with a complete line, we collect the last part of the buffer into a string called 'residue'. So we need to remember to keep it around for the start of the next buffer.

When we run out of file, we might still have some residue, so we add this to the vector as well.

Then, when we're done, we print out the vector to the screen.
_________________________
-- roger