mirror of
https://github.com/godotengine/godot.git
synced 2026-01-03 18:11:19 +03:00
Made Vector::ptrw explicit for writing, compiler was sometimes using the wrong function,
leading to unnecesary copy on writes and reduced performance.
This commit is contained in:
@@ -40,7 +40,7 @@ class StringBuffer {
|
||||
int string_length = 0;
|
||||
|
||||
_FORCE_INLINE_ CharType *current_buffer_ptr() {
|
||||
return static_cast<Vector<CharType> &>(buffer).empty() ? short_buffer : buffer.ptr();
|
||||
return static_cast<Vector<CharType> &>(buffer).empty() ? short_buffer : buffer.ptrw();
|
||||
}
|
||||
|
||||
public:
|
||||
|
||||
Reference in New Issue
Block a user