Opened 12 years ago

Closed 12 years ago

#4366 closed Bugs (fixed)

Graph with MPI fails to compile due to mismatch between size of types

Reported by: webmaster@… Owned by: ngedmond
Milestone: Boost 1.44.0 Component: graph
Version: Boost 1.43.0 Severity: Problem
Keywords: Cc:

Description

[BOOST_PATH]/boost/graph/distributed/unsafe_serialize.hpp(40) : error C2182: 'abstract declarator' : illegal use of type 'void'

This error occurs during x64 compilation with MSVC 10.0 under Windows 7 x64, where sizeof(int) != sizeof(void*) && sizeof(long) != sizeof(void*).

typedef mpl::if_c<(sizeof(int) == sizeof(void*)),

int, mpl::if_c<(sizeof(long) == sizeof(void*)), long, void>::type

::type ptr_serialize_type;

As Windows uses LLP64 model, which defines a long type as 32bit integer, two cascaded conditions fail. Then ptr_serialize_type is declared as a void type. I think it can be fixed with replacing the last 'void' with 'long long' or using conditional compilation for windows under x64.

Change History (4)

comment:1 by Jeremiah Willcock, 12 years ago

Owner: changed from Andrew Sutton to ngedmond

comment:2 by Jeremiah Willcock, 12 years ago

Could you please check this in the Boost trunk? It appears to have been fixed there.

comment:3 by webmaster@…, 12 years ago

I found the problem has been fixed in version 1.44. It was in version 1.43. Thanks.

comment:4 by Jeremiah Willcock, 12 years ago

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.