зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1839396 part 5 - Move GenericPrinter::flush after print/put functions. r=mgaudet
Differential Revision: https://phabricator.services.mozilla.com/D181490
This commit is contained in:
Родитель
f47981dfaa
Коммит
30f3d15e9e
|
@ -38,9 +38,6 @@ class JS_PUBLIC_API GenericPrinter {
|
|||
// Puts |len| characters from |s| at the current position and
|
||||
// return true on success, false on failure.
|
||||
virtual bool put(const char* s, size_t len) = 0;
|
||||
virtual void flush() { /* Do nothing */
|
||||
}
|
||||
|
||||
inline bool put(const char* s) { return put(s, strlen(s)); }
|
||||
inline bool putChar(const char c) { return put(&c, 1); }
|
||||
|
||||
|
@ -60,6 +57,10 @@ class JS_PUBLIC_API GenericPrinter {
|
|||
bool printf(const char* fmt, ...) MOZ_FORMAT_PRINTF(2, 3);
|
||||
bool vprintf(const char* fmt, va_list ap) MOZ_FORMAT_PRINTF(2, 0);
|
||||
|
||||
// In some printers, this ensure that the content is fully written.
|
||||
virtual void flush() { /* Do nothing */
|
||||
}
|
||||
|
||||
// Report that a string operation failed to get the memory it requested.
|
||||
virtual void reportOutOfMemory();
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче