tesseract v5.3.3.20231005
testing::internal::FunctionPointerPrinter Struct Reference

#include <gtest-printers.h>

Static Public Member Functions

template<typename T , typename = typename std::enable_if< std::is_function<T>::value>::type>
static void PrintValue (T *p, ::std::ostream *os)
 

Detailed Description

Definition at line 164 of file gtest-printers.h.

Member Function Documentation

◆ PrintValue()

template<typename T , typename = typename std::enable_if< std::is_function<T>::value>::type>
static void testing::internal::FunctionPointerPrinter::PrintValue ( T *  p,
::std::ostream *  os 
)
inlinestatic

Definition at line 167 of file gtest-printers.h.

167 {
168 if (p == nullptr) {
169 *os << "NULL";
170 } else {
171 // T is a function type, so '*os << p' doesn't do what we want
172 // (it just prints p as bool). We want to print p as a const
173 // void*.
174 *os << reinterpret_cast<const void*>(p);
175 }
176 }
const char * p

The documentation for this struct was generated from the following file: