Lars Gullik Bjønnes wrote:

> | No, I think uint32_t is also defined in the global namespace and
> | that's what gcc uses here. So I guess you'd better explicitly specify
> | boost::.
> 
> Hmm... that should only be used if stdint/inttypes has been included
> (and c++ used in C99 compaiblity mode)
> 

Abdel's patch includes  <boost/cstdint.hpp>

> | > but please add a
> | > 'using' statement instead.
> | > using boost::uint32_t;
> | 
> | If you want but you are using boost::uint32_t just two lines before.
> 
> Hmm... ok... boost::uint32_t it is then.
> 

So here the new patch:

Index: src/support/unicode.C
===================================================================
--- src/support/unicode.C       (revision 14663)
+++ src/support/unicode.C       (working copy)
@@ -14,6 +14,8 @@

 #include "unicode.h"

+#include <iconv.h>
+
 #include "debug.h"

 #include <cerrno>
@@ -45,7 +47,7 @@
                }
        }

-       char * inbuf = const_cast<char *>(&buf[0]);
+       char const * inbuf = &buf[0];
        size_t inbytesleft = buf.size();
        char out[1000] = { 0 };
        char * outbuf = out;
@@ -108,6 +110,7 @@
 {
        //lyxerr << "Outbuf =" << std::hex;

+       using boost::uint32_t;
        std::vector<uint32_t> ucs4;
        for (size_t i = 0; i < bytes.size(); i += 4) {
                unsigned char const b1 = bytes[i    ];


Reply via email to