• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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 
5 #include <boost/concept/usage.hpp>
6 #include <boost/core/ignore_unused.hpp>
7 
8 template <class T>
9 struct StringInitializable
10 {
11     typedef int associated;
BOOST_CONCEPT_USAGEStringInitializable12     BOOST_CONCEPT_USAGE(StringInitializable)
13     {
14         T x = "foo";
15         boost::ignore_unused(x);
16     }
17 };
18 
19 // Test that accessing an associated type will actually exercise usage
20 // requirements
21 typedef StringInitializable<int>::associated tee;
22 
23 
24 
25