return pos;
}
-void raw_fd_ostream::pwrite(const char *Ptr, size_t Size, uint64_t Offset) {
+void raw_fd_ostream::pwrite_impl(const char *Ptr, size_t Size,
+ uint64_t Offset) {
uint64_t Pos = tell();
seek(Offset);
write(Ptr, Size);
flush();
}
-void raw_svector_ostream::pwrite(const char *Ptr, size_t Size,
- uint64_t Offset) {
+void raw_svector_ostream::pwrite_impl(const char *Ptr, size_t Size,
+ uint64_t Offset) {
flush();
-
- uint64_t End = Offset + Size;
- if (End > OS.size())
- OS.resize(End);
-
memcpy(OS.begin() + Offset, Ptr, Size);
}
return 0;
}
-void raw_null_ostream::pwrite(const char *Ptr, size_t Size, uint64_t Offset) {}
+void raw_null_ostream::pwrite_impl(const char *Ptr, size_t Size,
+ uint64_t Offset) {}