tesseract v5.3.3.20231005
testing::internal::ReturnRefOfCopyAction< T > Class Template Reference

#include <gmock-actions.h>

Public Member Functions

 ReturnRefOfCopyAction (const T &value)
 
template<typename F >
 operator Action< F > () const
 

Detailed Description

template<typename T>
class testing::internal::ReturnRefOfCopyAction< T >

Definition at line 790 of file gmock-actions.h.

Constructor & Destructor Documentation

◆ ReturnRefOfCopyAction()

template<typename T >
testing::internal::ReturnRefOfCopyAction< T >::ReturnRefOfCopyAction ( const T &  value)
inlineexplicit

Definition at line 794 of file gmock-actions.h.

794: value_(value) {} // NOLINT
int value

Member Function Documentation

◆ operator Action< F >()

template<typename T >
template<typename F >
testing::internal::ReturnRefOfCopyAction< T >::operator Action< F > ( ) const
inline

Definition at line 799 of file gmock-actions.h.

799 {
800 typedef typename Function<F>::Result Result;
801 // Asserts that the function return type is a reference. This
802 // catches the user error of using ReturnRefOfCopy(x) when Return(x)
803 // should be used, and generates some helpful error message.
806 use_Return_instead_of_ReturnRefOfCopy_to_return_a_value);
807 return Action<F>(new Impl<F>(value_));
808 }
#define GTEST_COMPILE_ASSERT_(expr, msg)
Definition: gtest-port.h:879

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