alignment_traits.hpp:

- lots of parentheses for Borland C++

type_traits_test.hpp:
  - More parentheses for Borland C++
  - Move 'align_t' out of type_with_alignment test function 'do_it' (because Borland C++ wants it that way)


[SVN r13419]
This commit is contained in:
Douglas Gregor
2002-04-10 04:01:47 +00:00
parent 55e37c0fa0
commit e87486cf7b
2 changed files with 5 additions and 4 deletions

View File

@ -185,7 +185,7 @@ class type_with_alignment
typedef type_with_alignment<Align> this_type;
typedef typename detail::ct_if<
detail::is_aligned<alignment_of<t1>::value, Align>::value
(detail::is_aligned<(alignment_of<t1>::value), Align>::value)
, t1
, detail::max_align
>::type align_t;

View File

@ -200,11 +200,12 @@ struct test_align<T&>
template<class T>
struct test_type_with_align
{
typedef typename boost::type_with_alignment<
(boost::alignment_of<T>::value)>::type
align_t;
static void do_it()
{
typedef typename boost::type_with_alignment<
boost::alignment_of<T>::value>::type
align_t;
int align = boost::alignment_of<T>::value;
int new_align = boost::alignment_of<align_t>::value;
++test_count;