DP
std::size_t n = socket_.async_read_some(boost::asio::buffer(data), yield);
boost::asio::async_write(socket_, boost::asio::buffer(data, n), yield);
Size: a a a
DP
std::size_t n = socket_.async_read_some(boost::asio::buffer(data), yield);
boost::asio::async_write(socket_, boost::asio::buffer(data, n), yield);
DP
🎄T
Е
DP
Е
std::string buf;
while(readSomeData(buf,input)) { container.push_back(std::move(buf));}
DP
std::string buf;
while(readSomeData(buf,input)) { container.push_back(std::move(buf));}
buf = std::string(...)
TS
buf.clear();
можно делать что угодноЕ
buf.clear();
можно делать что угодноTS
buf = std::string(...)
DP
When an object is in an unspecified state, you can perform any operation on the object which has no preconditions. If there is an operation with preconditions you wish to perform, you can not directly perform that operation because you do not know if the unspecified-state of the object satisfies the preconditions.
Examples of operations that generally do not have preconditions:
destruction
assignment
const observers such as get, empty, size
Examples of operations that generally do have preconditions:
dereference
pop_back
DP
AF
auto tuple_one = getTuple<1>();
auto tuple_two = getTuple<2>();
for (int i = 0; i < std::tuple_size_v(tuple_two);++i)
container.insert({get<i>(tuple_one),get<i>(tuple_two)
})
Е
AK
AF
AF
TS
AK
AK
auto tuple_one = getTuple<1>();
auto tuple_two = getTuple<2>();
for (int i = 0; i < std::tuple_size_v(tuple_two);++i)
container.insert({get<i>(tuple_one),get<i>(tuple_two)
})