streams.hpp
Go to the documentation of this file.
1 
8 /*****************************************************************************
9 ** Ifdefs
10 *****************************************************************************/
11 
12 #ifndef ECL_CONCEPTS_STREAMS_HPP_
13 #define ECL_CONCEPTS_STREAMS_HPP_
14 
15 /*****************************************************************************
16 ** Includes
17 *****************************************************************************/
18 
19 #include "macros.hpp"
20 
21 /*****************************************************************************
22 ** Namespaces
23 *****************************************************************************/
24 
25 namespace ecl {
26 
27 /*****************************************************************************
28 ** Concept [Stream]
29 *****************************************************************************/
30 
37 template <typename Implementation>
39  public:
40 
50  {
51  stream << 'a';
52  stream.flush();
53  }
54 
55  private:
56  // Putting instantiations here actually saves instantiation (which can cause a
57  // problem if there is no default constructor).
58  Implementation stream;
59 };
60 
61 }; // namespace ecl
62 
63 #endif /* ECL_CONCEPTS_STREAMS_HPP_ */
Embedded control libraries.
Implementation stream
Definition: streams.hpp:58
Defines validating functionality for the streams concept.
Definition: streams.hpp:38
Mechanisms enabling compile time checking of metaprogramming concepts.
ecl_compile_time_concept_test(StreamConcept)
Implements a concept test for streams.
Definition: streams.hpp:49


ecl_concepts
Author(s): Daniel Stonier
autogenerated on Mon Feb 28 2022 22:18:33