• Marco Bubke's avatar
    Utils: Add SmallString · 1eb0c94f
    Marco Bubke authored
    SmallString is a very simple utf8 string class. It's purpose is performance.
    It uses a short string opimization which provides 31 bytes of heap free
    memory to save a 30 bytes long string plus null terminator. If the string
    gets larger heap is allocated. The grow strategy is 1.5 to improve reuse
    of allocated memory.
    It uses optionally constexpr to provide string literals.
    Change-Id: I7757fb51abfeca200d074cbfce2f1d99edc0ecb0
    Reviewed-by: default avatarTobias Hunger <tobias.hunger@theqtcompany.com>
utils.qbs 8.57 KB