Opened 14 years ago

Closed 14 years ago

#2840 closed Bugs (invalid)

[type traits] is_pod<T>::value != BOOST_IS_POD(T)

Reported by: johan.torp@… Owned by: John Maddock
Milestone: To Be Determined Component: type_traits
Version: Boost 1.38.0 Severity: Not Applicable
Keywords: Cc:

Description

According to boost/type_traits/intrinsics.hpp: BOOST_IS_POD(T) should evaluate to true if T is a POD type

This is not true for MSVC.

Excerpted from the is_pod documentation at http://msdn.microsoft.com/en-us/library/ms177194.aspx:

"Returns true if the type is a class or union with no constructor or private or protected non-static members, no base classes, and no virtual functions. See the C++ standard, sections 8.5.1/1, 9/4, and 3.9/10 for more information on PODs.

is_pod will return false on fundamental types."

Note that is_pod works fine.

Best Regards, Johan Torp www.johantorp.com

Change History (3)

comment:1 by Steven Watanabe, 14 years ago

Component: Nonetype_traits
Owner: set to John Maddock

comment:2 by John Maddock, 14 years ago

Forgive me, but where's the bug?

BOOST_IS_POD is an internal helper macro, so as long as boost::is_pod does the correct thing, what's the problem?

Regards, John Maddock.

comment:3 by John Maddock, 14 years ago

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