Base: fix warnings reported by code analysers
* disable copy-constructor and assignment operator for Stream classes * remove destructor of sub-classes of SequencerBase * fix some old C-style cast warnings
This commit is contained in:
@@ -52,6 +52,8 @@ public:
|
||||
|
||||
protected:
|
||||
Stream();
|
||||
Stream(const Stream&) = default;
|
||||
Stream& operator=(const Stream&) = default;
|
||||
virtual ~Stream();
|
||||
|
||||
bool _swap;
|
||||
@@ -147,6 +149,10 @@ protected:
|
||||
std::ios_base::openmode which =
|
||||
std::ios::in | std::ios::out);
|
||||
|
||||
private:
|
||||
ByteArrayOStreambuf(const ByteArrayOStreambuf&);
|
||||
ByteArrayOStreambuf& operator=(const ByteArrayOStreambuf&);
|
||||
|
||||
private:
|
||||
QBuffer* _buffer;
|
||||
};
|
||||
@@ -174,6 +180,9 @@ protected:
|
||||
virtual pos_type seekpos(std::streambuf::pos_type pos,
|
||||
std::ios_base::openmode which =
|
||||
std::ios::in | std::ios::out);
|
||||
private:
|
||||
ByteArrayIStreambuf(const ByteArrayIStreambuf&);
|
||||
ByteArrayIStreambuf& operator=(const ByteArrayIStreambuf&);
|
||||
|
||||
private:
|
||||
const QByteArray& _buffer;
|
||||
@@ -201,6 +210,10 @@ protected:
|
||||
virtual pos_type seekpos(std::streambuf::pos_type sp,
|
||||
std::ios_base::openmode which =
|
||||
std::ios::in | std::ios::out);
|
||||
private:
|
||||
IODeviceOStreambuf(const IODeviceOStreambuf&);
|
||||
IODeviceOStreambuf& operator=(const IODeviceOStreambuf&);
|
||||
|
||||
protected:
|
||||
QIODevice* device;
|
||||
};
|
||||
@@ -225,6 +238,9 @@ protected:
|
||||
virtual pos_type seekpos(std::streambuf::pos_type sp,
|
||||
std::ios_base::openmode which =
|
||||
std::ios::in | std::ios::out);
|
||||
private:
|
||||
IODeviceIStreambuf(const IODeviceIStreambuf&);
|
||||
IODeviceIStreambuf& operator=(const IODeviceIStreambuf&);
|
||||
|
||||
protected:
|
||||
QIODevice* device;
|
||||
@@ -270,6 +286,10 @@ private:
|
||||
bool flushBuffer();
|
||||
bool writeStr(const char* s, std::streamsize num);
|
||||
|
||||
private:
|
||||
PyStreambuf(const PyStreambuf&);
|
||||
PyStreambuf& operator=(const PyStreambuf&);
|
||||
|
||||
private:
|
||||
PyObject* inp;
|
||||
Type type;
|
||||
@@ -296,6 +316,10 @@ protected:
|
||||
std::ios_base::openmode which =
|
||||
std::ios::in | std::ios::out);
|
||||
|
||||
private:
|
||||
Streambuf(const Streambuf&);
|
||||
Streambuf& operator=(const Streambuf&);
|
||||
|
||||
private:
|
||||
std::string::const_iterator _beg;
|
||||
std::string::const_iterator _end;
|
||||
|
||||
Reference in New Issue
Block a user