BVB Source Codes

mars Show blank.hpp Source code

Return Download mars: download blank.hpp Source code - Download mars Source code - Type:.hpp
  1. //-----------------------------------------------------------------------------
  2. // boost blank.hpp header file
  3. // See http://www.boost.org for updates, documentation, and revision history.
  4. //-----------------------------------------------------------------------------
  5. //
  6. // Copyright (c) 2003
  7. // Eric Friedman
  8. //
  9. // Distributed under the Boost Software License, Version 1.0. (See
  10. // accompanying file LICENSE_1_0.txt or copy at
  11. // http://www.boost.org/LICENSE_1_0.txt)
  12.  
  13. #ifndef BOOST_BLANK_HPP
  14. #define BOOST_BLANK_HPP
  15.  
  16. #include "boost/blank_fwd.hpp"
  17.  
  18. #if !defined(BOOST_NO_IOSTREAM)
  19. #include <iosfwd> // for std::basic_ostream forward declare
  20. #include "boost/detail/templated_streams.hpp"
  21. #endif // BOOST_NO_IOSTREAM
  22.  
  23. #include "boost/mpl/bool.hpp"
  24. #include "boost/type_traits/is_empty.hpp"
  25. #include "boost/type_traits/is_pod.hpp"
  26. #include "boost/type_traits/is_stateless.hpp"
  27.  
  28. namespace mars_boost {} namespace boost = mars_boost; namespace mars_boost {
  29.  
  30. struct blank
  31. {
  32. };
  33.  
  34. // type traits specializations
  35. //
  36.  
  37. template <>
  38. struct is_pod< blank >
  39.     : mpl::true_
  40. {
  41. };
  42.  
  43. template <>
  44. struct is_empty< blank >
  45.     : mpl::true_
  46. {
  47. };
  48.  
  49. template <>
  50. struct is_stateless< blank >
  51.     : mpl::true_
  52. {
  53. };
  54.  
  55. // relational operators
  56. //
  57.  
  58. inline bool operator==(const blank&, const blank&)
  59. {
  60.     return true;
  61. }
  62.  
  63. inline bool operator<=(const blank&, const blank&)
  64. {
  65.     return true;
  66. }
  67.  
  68. inline bool operator>=(const blank&, const blank&)
  69. {
  70.     return true;
  71. }
  72.  
  73. inline bool operator!=(const blank&, const blank&)
  74. {
  75.     return false;
  76. }
  77.  
  78. inline bool operator<(const blank&, const blank&)
  79. {
  80.     return false;
  81. }
  82.  
  83. inline bool operator>(const blank&, const blank&)
  84. {
  85.     return false;
  86. }
  87.  
  88. // streaming support
  89. //
  90. #if !defined(BOOST_NO_IOSTREAM)
  91.  
  92. BOOST_TEMPLATED_STREAM_TEMPLATE(E,T)
  93. inline BOOST_TEMPLATED_STREAM(ostream, E,T)& operator<<(
  94.       BOOST_TEMPLATED_STREAM(ostream, E,T)& out
  95.     , const blank&
  96.     )
  97. {
  98.     // (output nothing)
  99.     return out;
  100. }
  101.  
  102. #endif // BOOST_NO_IOSTREAM
  103.  
  104. } // namespace mars_boost
  105.  
  106. #endif // BOOST_BLANK_HPP
  107.  
downloadblank.hpp Source code - Download mars Source code
Related Source Codes/Software:
Hero - Elegant transition library for iOS & tvOS 2017-06-09
deep-photo-styletransfer - Code and data for paper "Deep Photo Style Transfer... 2017-06-09
mastodon - A GNU Social-compatible microblogging server ... 2017-06-09
plyr - A simple HTML5, YouTube and Vimeo player ... 2017-06-08
prepack - Prepack is a partial evaluator for JavaScript. Pre... 2017-06-08
Public-APIs - 2017-06-09
lottie-ios - An iOS library to natively render After Effects ve... 2017-06-09
Awesome-Hacking - A collection of various awesome lists for hackers,... 2017-06-09
algorithms - Minimal examples of data structures and algorithms... 2017-06-10
lectures - Oxford Deep NLP 2017 course 2017-06-10
CRYENGINE - CRYENGINE is a powerful real-time game development... 2017-06-11
postal - 2017-06-11
reactide - Reactide is the first dedicated IDE for React web ... 2017-06-11
rkt - rkt is a pod-native container engine for Linux. It... 2017-06-11
uWebSockets - Tiny WebSockets https://for... 2017-06-11
realworld - TodoMVC for the RealWorld - Exemplary fullstack Me... 2017-06-11
goreplay - GoReplay is an open-source tool for capturing and ... 2017-06-10
pyenv - Simple Python version management 2017-06-10
redux-saga - An alternative side effect model for Redux apps ... 2017-06-10
angular-starter - 2017-06-10

 Back to top