Coverage Report

Created: 2023-06-07 06:25

/src/boost/boost/describe/detail/cx_streq.hpp
Line
Count
Source (jump to first uncovered line)
1
#ifndef BOOST_DESCRIBE_DETAIL_CX_STREQ_HPP_INCLUDED
2
#define BOOST_DESCRIBE_DETAIL_CX_STREQ_HPP_INCLUDED
3
4
// Copyright 2021 Peter Dimov
5
// Distributed under the Boost Software License, Version 1.0.
6
// https://www.boost.org/LICENSE_1_0.txt
7
8
#include <boost/describe/detail/config.hpp>
9
10
#if defined(BOOST_DESCRIBE_CXX11)
11
12
namespace boost
13
{
14
namespace describe
15
{
16
namespace detail
17
{
18
19
constexpr bool cx_streq( char const * s1, char const * s2 )
20
0
{
21
0
    return s1[0] == s2[0] && ( s1[0] == 0 || cx_streq( s1 + 1, s2 + 1 ) );
22
0
}
23
24
} // namespace detail
25
} // namespace describe
26
} // namespace boost
27
28
#endif // defined(BOOST_DESCRIBE_CXX11)
29
30
#endif // #ifndef BOOST_DESCRIBE_DETAIL_CX_STREQ_HPP_INCLUDED