source: vendor/nemo/current/NEMOGCM/EXTERNAL/XIOS/extern/boost/include/boost/concept/usage.hpp @ 44

Last change on this file since 44 was 44, checked in by cholod, 12 years ago

Load NEMO_TMP into vendor/nemo/current.

File size: 1.2 KB
Line 
1// Copyright David Abrahams 2006. Distributed under the Boost
2// Software License, Version 1.0. (See accompanying
3// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
4#ifndef BOOST_CONCEPT_USAGE_DWA2006919_HPP
5# define BOOST_CONCEPT_USAGE_DWA2006919_HPP
6
7# include <boost/concept/assert.hpp>
8# include <boost/detail/workaround.hpp>
9# include <boost/concept/detail/backward_compatibility.hpp>
10
11namespace boost { namespace concepts { 
12
13# if BOOST_WORKAROUND(__GNUC__, == 2)
14
15#  define BOOST_CONCEPT_USAGE(model) ~model()
16
17# else
18
19template <class Model>
20struct usage_requirements
21{
22    ~usage_requirements() { ((Model*)0)->~Model(); }
23};
24
25#  if BOOST_WORKAROUND(__GNUC__, <= 3)
26
27#   define BOOST_CONCEPT_USAGE(model)                                    \
28      model(); /* at least 2.96 and 3.4.3 both need this :( */           \
29      BOOST_CONCEPT_ASSERT((boost::concepts::usage_requirements<model>)); \
30      ~model()
31
32#  else
33
34#   define BOOST_CONCEPT_USAGE(model)                                    \
35      BOOST_CONCEPT_ASSERT((boost::concepts::usage_requirements<model>)); \
36      ~model()
37
38#  endif
39
40# endif
41
42}} // namespace boost::concepts
43
44#endif // BOOST_CONCEPT_USAGE_DWA2006919_HPP
Note: See TracBrowser for help on using the repository browser.