Subject: [Boost-bugs] [Boost C++ Libraries] #10838: Missing std:: qualifier for strlen calls in string_ref_test2.cpp
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2014-12-02 19:06:25
#10838: Missing std:: qualifier for strlen calls in string_ref_test2.cpp
-------------------------------------------+---------------------------
Reporter: Aparna Kumta <Aparna.Kumta@â¦> | Owner: no-maintainer
Type: Bugs | Status: new
Milestone: To Be Determined | Component: utility
Version: Boost Development Trunk | Severity: Problem
Keywords: |
-------------------------------------------+---------------------------
Compiling with Oracle Solaris Studio on Solaris 11.2, we see
"../libs/utility/test/string_ref_test2.cpp", line 21: Error: The function
"strlen" must have a prototype.
"../libs/utility/test/string_ref_test2.cpp", line 51: Error: The function
"strlen" must have a prototype.
"../libs/utility/test/string_ref_test2.cpp", line 162: Error: The function
"strlen" must have a prototype.
"../libs/utility/test/string_ref_test2.cpp", line 183: Error: The function
"strlen" must have a prototype.
The file libs/utility/test/string_ref_test2.cpp includes <cstring>,
however strlen needs to be qualified with std::
The diffs are
21c21
< const size_t sz = strlen ( arg );
---
> const size_t sz = std::strlen ( arg );
51c51
< const size_t sz = strlen ( arg );
---
> const size_t sz = std::strlen ( arg );
162c162
< p = arg + strlen ( arg ) - 1;
---
> p = arg + std::strlen ( arg ) - 1;
183c183
< p = arg + strlen ( arg ) - 1;
---
> p = arg + std::strlen ( arg ) - 1;
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/10838> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:17 UTC