diff options
author | Marcelo Fernandez <marcelofg55@gmail.com> | 2018-03-22 00:17:18 -0300 |
---|---|---|
committer | Marcelo Fernandez <marcelofg55@gmail.com> | 2018-03-22 00:17:18 -0300 |
commit | 35d21c08813242002e31f1d9bbc45fed5a21ebde (patch) | |
tree | 60bce83ab5f359d83ee2537977c306d1ba7eba2b /core/string_buffer.h | |
parent | f2df8c94b2e5ba6c4eee3515d1d30f36194ca803 (diff) | |
download | redot-engine-35d21c08813242002e31f1d9bbc45fed5a21ebde.tar.gz |
Fix several in-class initialization clang warning
Diffstat (limited to 'core/string_buffer.h')
-rw-r--r-- | core/string_buffer.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/core/string_buffer.h b/core/string_buffer.h index b148e45544..7e9b151bea 100644 --- a/core/string_buffer.h +++ b/core/string_buffer.h @@ -39,7 +39,7 @@ class StringBuffer { CharType short_buffer[SHORT_BUFFER_SIZE]; String buffer; - int string_length = 0; + int string_length; _FORCE_INLINE_ CharType *current_buffer_ptr() { return static_cast<Vector<CharType> &>(buffer).empty() ? short_buffer : buffer.ptrw(); @@ -79,6 +79,10 @@ public: _FORCE_INLINE_ operator String() { return as_string(); } + + StringBuffer() { + string_length = 0; + } }; template <int SHORT_BUFFER_SIZE> |