move function to avoid duplicate

This commit is contained in:
Maxime Gimeno 2021-01-08 13:02:05 +01:00
parent cce00dd29f
commit fe12d897f9
1 changed files with 1 additions and 12 deletions

View File

@ -19,6 +19,7 @@
#include <CGAL/assertions.h>
#include <CGAL/IO/io.h>
#include <CGAL/IO/VTK/VTK_writer.h>
#include <iostream>
#include <vector>
@ -32,18 +33,6 @@ namespace CGAL {
namespace IO {
namespace internal {
template <class FT>
void
write_vector(std::ostream& os,
const std::vector<FT>& vect)
{
const char* buffer = reinterpret_cast<const char*>(&(vect[0]));
std::size_t size = vect.size()*sizeof(FT);
os.write(reinterpret_cast<const char *>(&size), sizeof(std::size_t)); // number of bytes encoded
os.write(buffer, vect.size()*sizeof(FT)); // encoded data
}
// writes the cells tags before binary data is appended
template <class CDT>