MacOS portability improvements.

Added a class to encapsulate Mac vs. Unix path separator differences.
This commit is contained in:
curt
1999-04-27 15:56:22 +00:00
parent f8dde93e05
commit 5bddbd0ca9
4 changed files with 161 additions and 7 deletions
+11 -7
View File
@@ -98,18 +98,22 @@ skipeol( istream& in )
while ( in.get(c) && (c != '\n' && c != '\r') )
;
// \r\n ?
#ifdef __MWERKS // -dw- need to strip line ending!
in >> skipws;
#endif
return in;
}
istream&
skipws( istream& in )
{
skipws( istream& in ) {
char c;
while ( in.get(c) )
{
if ( ! isspace( c ) )
{
while ( in.get(c) ) {
#ifdef __MWERKS__ // -dw- for unix file compatibility
if ( ! (isspace( c ) ) || c != '\0' || c!='\n' || c != '\r' ) {
#else
if ( ! isspace( c ) ) {
#endif
// put pack the non-space character
in.putback(c);
break;