4#include "../Containers/Array.h"
5#include "../Strings/String.h"
6#include "../Strings/StringConverter.h"
31 alignof(SegmentHeader),
48 String::data =
move(data);
54 String::data =
move(other.data);
60 String::data = other.data;
103 SegmentHeader* header = SegmentHeader::getSegmentHeader(buffer.items);
104 header->isSmallVector =
true;
105 String::data.items = buffer.items;
#define SC_COMPILER_WARNING_POP
Pops warning from inside a macro.
Definition: Compiler.h:107
#define SC_COMPILER_EXPORT
Macro for symbol visibility in non-MSVC compilers.
Definition: Compiler.h:78
#define SC_COMPILER_OFFSETOF(Class, Field)
Returns offset of Class::Field in bytes.
Definition: Compiler.h:111
#define SC_COMPILER_EXTERN
Define compiler-specific export macros for DLL visibility.
Definition: Compiler.h:74
#define SC_ASSERT_RELEASE(e)
Assert expression e to be true.
Definition: Assert.h:66
#define SC_COMPILER_WARNING_PUSH_OFFSETOF
Disables invalid-offsetof gcc and clang warning.
Definition: Compiler.h:131
constexpr T && move(T &value)
Converts an lvalue to an rvalue reference.
Definition: Compiler.h:269
char native_char_t
The native char for the platform (wchar_t (4 bytes) on Windows, char (1 byte) everywhere else )
Definition: PrimitiveTypes.h:34
StringEncoding
String Encoding (Ascii, Utf8, Utf16)
Definition: StringIterator.h:17
@ Ascii
Encoding is ASCII.
A contiguous sequence of elements kept inside its inline storage.
Definition: Array.h:43
String with compile time configurable inline storage (small string optimization)
Definition: SmallString.h:21
A non-modifiable owning string with associated encoding.
Definition: String.h:30
bool assign(StringView sv)
Assigns a StringView to this String, replacing existing contents.
Definition: String.h:175
String(StringEncoding encoding=StringEncoding::Utf8)
Builds an empty String with a given Encoding.
Definition: String.h:33
StringView view() const SC_LANGUAGE_LIFETIME_BOUND
Obtain a null-terminated StringView from current String.
Definition: String.h:200
String & operator=(const char(&text)[N])
Assigns an ascii string literal to current String.
Definition: String.h:131
Non-owning view over a range of characters with UTF Encoding.
Definition: StringView.h:47
constexpr StringEncoding getEncoding() const
Get encoding of this StringView.
Definition: StringView.h:93
A contiguous sequence of heap allocated elements.
Definition: Vector.h:51