Reading and storing the newline character alongside data!

I am reading data from a text file into a program. I am well aware of the subtle distinctions in the mode of data input/entry when using the stream extraction operator, the get() function, and the getline() function. My problem is that all of them do not read and/or store the newline character alongside the data read!

Does anyone know a function that reads and stores data and the terminating newline character together?? Thank you.
What's wrong with using get or getline and then storing the newline yourself?

If you want to load the entire text file into a single block of memory all at once, you can use read as in the example on this page:
http://www.cplusplus.com/reference/istream/istream/read/
Topic archived. No new replies allowed.