]> git.lyx.org Git - lyx.git/blobdiff - src/support/DebugStream.h
noncopyable + read ChangeLog
[lyx.git] / src / support / DebugStream.h
index 9e87488a087a0ecd212e983ca9e97997f093edb4..703bbdf4fbeb2b344e030137e1d64dc13054df13 100644 (file)
 #ifndef DEBUGSTREAM_H
 #define DEBUGSTREAM_H
 
+#ifdef __GNUG__
+#pragma interface
+#endif
+
 #include "LOstream.h"
 
 #ifdef TEST_DEBUGSTREAM
@@ -82,7 +86,16 @@ struct Debug {
     debug[Debug::type(Debug::INFO | Debug::CRIT)] << "...info/crit...\n";
 
 */
-class DebugStream : public std::ostream {
+
+// This workaround is needed only for gcc 2.8.1 (and possibly egcs
+// 1.0.x), which generates a compiler error when subclassing from
+// std::. (JMarc)
+#ifdef CXX_WORKING_NAMESPACES
+class DebugStream : public std::ostream
+#else
+class DebugStream : public ostream
+#endif
+{
 public:
        /// Constructor, sets the debug level to t.
        explicit DebugStream(Debug::type t = Debug::NONE);