Re: [anjuta-devel] Clang and the include files



Hi,

If you don't find a solution, try to create a simple test program that you can run with valgrind. You can run anjuta in valgrind but it's damn
slow - it gives good results usually though.
It seems to work now.

For the posterity: I think the mistake was that I used a signed integer and not an unsigned offset for the offset.

before:
gint offset = ianjuta_iterable_get_position (iter, NULL)
CXSourceLocation location = clang_getLocationForOffset (clang_tu, clang_file, offset);

after:
guint offset = ianjuta_iterable_get_position (iter, NULL)
CXSourceLocation location = clang_getLocationForOffset (clang_tu, clang_file, offset);

But as I know from the technical informatic you can use signed integers as unsigned integers, if you prevent an overflow. Or I'm wrong?

Regards,
Moritz



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]