feat: add tr_strbuf (#2810)

* feat: add tr_strbuf class for building tmp strings

Based on fmt::basic_memory_buf, this is a growable string buffer that
has an initial size that's large enough to build most filenames or URLs
without needing heap allocations.

Adds a couple of extra helpers such as a `c_str()` method to make dealing
with old zero-terminated string APIs easier.
This commit is contained in:
Charles Kerr
2022-03-24 16:41:29 -05:00
committed by GitHub
parent 783fa500e7
commit 6e8f9f3ff0
9 changed files with 322 additions and 17 deletions

View File

@@ -13,11 +13,6 @@ include_directories(
SYSTEM
${CURL_INCLUDE_DIRS}
${EVENT2_INCLUDE_DIRS}
${LIBFMT_INCLUDE_DIRS}
)
add_definitions(
${LIBFMT_DEFINITIONS}
)
set(${PROJECT_NAME}_SOURCES