diff options
author | Andy Cedilnik <andy.cedilnik@kitware.com> | 2003-07-07 21:45:51 (GMT) |
---|---|---|
committer | Andy Cedilnik <andy.cedilnik@kitware.com> | 2003-07-07 21:45:51 (GMT) |
commit | 197368d9e7890cf4bcb36d40cb15413a8209aaca (patch) | |
tree | a1afe04481e0c979922c8df1b6f5ffa020f94a66 /Source/kwsys/SystemTools.hxx.in | |
parent | 42731475dc18a0112cff8974352c7b622e87555d (diff) | |
download | CMake-197368d9e7890cf4bcb36d40cb15413a8209aaca.zip CMake-197368d9e7890cf4bcb36d40cb15413a8209aaca.tar.gz CMake-197368d9e7890cf4bcb36d40cb15413a8209aaca.tar.bz2 |
ENH: Add optional argument to GetLineFromStream which can let the caller know whether there was a new line character at the end of the line that was just read
Diffstat (limited to 'Source/kwsys/SystemTools.hxx.in')
-rw-r--r-- | Source/kwsys/SystemTools.hxx.in | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Source/kwsys/SystemTools.hxx.in b/Source/kwsys/SystemTools.hxx.in index c59529f..a0c0d31 100644 --- a/Source/kwsys/SystemTools.hxx.in +++ b/Source/kwsys/SystemTools.hxx.in @@ -245,9 +245,11 @@ public: * Read line from file. Make sure to get everything. Due to a buggy stream * library on the HP and another on Mac OSX, we need this very carefully * written version of getline. Returns true if any data were read before the - * end-of-file was reached. + * end-of-file was reached. If the has_newline argument is specified, it will + * be true when the line read had a newline character. */ - static bool GetLineFromStream(kwsys_std::istream& istr, kwsys_std::string& line); + static bool GetLineFromStream(kwsys_std::istream& istr, kwsys_std::string& line, + bool* has_newline=0); protected: // these two functions can be called from ConvertToOutputPath |