Opened 13 years ago

Closed 13 years ago

Last modified 13 years ago

#3346 closed Bugs (fixed)

enum_t in scoped_enum_emulation.hpp conflicts with system header <rpc/types.h>

Reported by: Matthias Troyer Owned by: Beman Dawes
Milestone: Boost 1.40.0 Component: filesystem
Version: Boost Release Branch Severity: Regression
Keywords: Cc:

Description

The UNIX system header <rpc/types.h> defines a macro

#define enum_t int

This clashes with the enum_t member in boost/detail/scoped_enum_emulation.hpp

As a consequence there is a compilation error in Boost.Filesystem if any of the RPC headers is included before boost/filesystem/operations.hpp

This is a regression that can easily be fixed by renaming enum_t to enum_type in boost/detail/scoped_enum_emulation.hpp

the test program is trivial:

#include <rpc/types.h> #include <boost/filesystem/operations.hpp>

Change History (2)

comment:1 by Beman Dawes, 13 years ago

Resolution: fixed
Status: newclosed

(In [55604]) Fix #3346 boost/detail/scoped_enum_emulation.hpp enum_t conflict with Unix rpc/types.h

comment:2 by Daniel James, 13 years ago

(In [59679]) Merge some detail changes.

  • [53670] Avoid C style casts.
  • [55604] Fix #3346 boost/detail/scoped_enum_emulation.hpp enum_t conflict with Unix rpc/types.h
  • Don't foward declare containers when using gcc's parallel library and add a macro to disable forward declaration. Fixes #3866.
Note: See TracTickets for help on using tickets.