Merge pull request #84 from Flamefire/constref

Use const-ref for instance string
This commit is contained in:
Mathieu Champlon 2020-05-19 05:41:25 -05:00 committed by GitHub
commit 6b3a447a1b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -63,7 +63,7 @@
mutable mock::detail::function< MOCK_FUNCTION_TYPE((S), tpn) > t##_mock_; \ mutable mock::detail::function< MOCK_FUNCTION_TYPE((S), tpn) > t##_mock_; \
mock::detail::function< MOCK_FUNCTION_TYPE((S), tpn) >& t##_mock( \ mock::detail::function< MOCK_FUNCTION_TYPE((S), tpn) >& t##_mock( \
const mock::detail::context&, \ const mock::detail::context&, \
boost::unit_test::const_string instance ) const \ const boost::unit_test::const_string& instance ) const \
{ \ { \
mock::detail::configure( *this, t##_mock_, \ mock::detail::configure( *this, t##_mock_, \
instance.substr( 0, instance.rfind( BOOST_PP_STRINGIZE(t) ) ), \ instance.substr( 0, instance.rfind( BOOST_PP_STRINGIZE(t) ) ), \