Classes | Functions
fhicl::detail::yes_defaults Namespace Reference

Classes

struct  maybe_quotes
 
struct  maybe_quotes< std::string >
 

Functions

std::ostream & operator<< (std::ostream &os, maybe_quotes< bool > &&mq)
 
template<typename T >
std::enable_if_t<!std::is_floating_point< T >::value, std::ostream & > operator<< (std::ostream &os, maybe_quotes< T > &&mq)
 
template<typename T >
std::enable_if_t< std::is_floating_point< T >::value, std::ostream & > operator<< (std::ostream &os, maybe_quotes< T > &&mq)
 

Function Documentation

std::ostream& fhicl::detail::yes_defaults::operator<< ( std::ostream &  os,
maybe_quotes< bool > &&  mq 
)
inline

Definition at line 31 of file ostream_helpers.h.

32  {
33  return os << std::boolalpha << mq.value;
34  }
template<typename T >
std::enable_if_t<std::is_floating_point<T>::value, std::ostream&> fhicl::detail::yes_defaults::operator<< ( std::ostream &  os,
maybe_quotes< T > &&  mq 
)
inline

Definition at line 45 of file ostream_helpers.h.

46  {
47  return os << std::showpoint << mq.value;
48  }
template<typename T >
std::enable_if_t<!std::is_floating_point<T>::value, std::ostream&> fhicl::detail::yes_defaults::operator<< ( std::ostream &  os,
maybe_quotes< T > &&  mq 
)
inline

Definition at line 38 of file ostream_helpers.h.

39  {
40  return os << mq.value;
41  }