Re: [Boost-bugs] [Boost C++ Libraries] #11748: boost::asio::buffer() overload for string_ref and const char pointer (c-string)

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #11748: boost::asio::buffer() overload for string_ref and const char pointer (c-string)
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2015-11-06 12:38:39


#11748: boost::asio::buffer() overload for string_ref and const char pointer
(c-string)
-------------------------------+----------------------------
  Reporter: oliora@… | Owner: chris_kohlhoff
      Type: Feature Requests | Status: new
 Milestone: To Be Determined | Component: asio
   Version: Boost 1.57.0 | Severity: Optimization
Resolution: | Keywords: buffer
-------------------------------+----------------------------

Comment (by oliora@…):

 Ctor for `string_ref`:

 {{{#!cpp
 template<class Traits>
 inline const_buffers_1 buffer(const boost::basic_string_ref<char, Traits>&
 s) {
     return buffer(s.data(), s.size());
 }
 }}}

 P.S. In previous example I forgot `inline`.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/11748#comment:3>
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:19 UTC