boostorg / boostorg/container

New container: double ended string?

Open
#298 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
127
Forks
126
Avg merge
18h 53m
Merged PRs (30d)
1

Description

By analogy with `boost::container::devector`, I think it would be useful to have a `boost::container::destring`.

One of possible use cases is to create complicated concatenation chains without memory allocations(just my opinion, not sure does it worth, not sure does anybody really want it):

```
boost::container::destring str = "Hello world";
str.reserve(str.size() + 2); // prepare to insert one element front and yet one back
const auto braced_str = "(" + std::move(str) + ")"; // no memory allocation at all
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.