]> git.mxchange.org Git - simgear.git/blobdiff - simgear/misc/sgstream.cxx
Better error reporting for effects
[simgear.git] / simgear / misc / sgstream.cxx
index 484dce73277d6fc34bf1425315f1ab976b186e04..6d5352c86ae2a6f1cefa845cd3d6cfb6df648318 100644 (file)
 // $Id$
 
 #include <simgear/compiler.h>
-#include STL_STRING 
-
+#include <string>
 #include <ctype.h> // isspace()
-
-#ifdef SG_HAVE_STD_INCLUDES
-# include <cerrno>
-#else
-# include <errno.h>
-#endif
+#include <cerrno>
 
 #include "sgstream.hxx"
 
@@ -109,11 +103,7 @@ skipeol( istream& in )
     char c = '\0';
     // skip to end of line.
 
-#ifdef __MWERKS__
-    while ( in.get(c) && c != '\0' ) {
-#else
     while ( in.get(c) ) {
-#endif
        if ( (c == '\n') || (c == '\r') ) {
            break;
        }       
@@ -125,17 +115,9 @@ skipeol( istream& in )
 istream&
 skipws( istream& in ) {
     char c;
-#ifdef __MWERKS__
-    while ( in.get(c) && c != '\0' ) {
-#else
     while ( in.get(c) ) {
-#endif
 
-#ifdef __MWERKS__
-       if ( ! isspace( c ) && c != '\n' ) {
-#else
        if ( ! isspace( c ) ) {
-#endif
            // put pack the non-space character
            in.putback(c);
            break;
@@ -150,11 +132,7 @@ skipcomment( istream& in )
     while ( in )
     {
        // skip whitespace
-#ifdef __MWERKS__
-       in >> ::skipws;
-#else
        in >> skipws;
-#endif
 
        char c;
        if ( in.get( c ) && c != '#' )