[Uml-devel] KDE/kdesdk/umbrello/umbrello/codeimport/kdevcppparser

Jean Vittor jean.vittor at free.fr
Tue Mar 25 20:16:17 UTC 2008


SVN commit 790073 by jvittor:

Compile fix. Supposed to work for boost 1.33.1 or 1.34.1

 M  +12 -2     position.h  


--- trunk/KDE/kdesdk/umbrello/umbrello/codeimport/kdevcppparser/position.h #790072:790073
@@ -20,12 +20,22 @@
 #ifndef _Position_H_
 #define _Position_H_
 
-#include <limits.h>             // Boost spirit headers aren't self-contained
+#include <boost/version.hpp>
 #include <boost/spirit.hpp>
-#include <QChar>
 
+#if BOOST_VERSION == 103301
+
+typedef boost::spirit::file_position Position;
+
+#elif BOOST_VERSION == 103401
+# include <QChar>
+
 typedef boost::spirit::file_position_base<std::basic_string<QChar> > Position;
 
+#else
+# error Unknown version of boost lib
+#endif
+
 inline bool operator<( Position const& p1, Position const& p2) {
   assert( p1.file == p2.file);
   return( (p1.line < p2.line)




More information about the umbrello-devel mailing list