mirror of https://github.com/AxioDL/metaforce.git
Initialization-order clarification
This commit is contained in:
parent
6efe4417d7
commit
805dc19d4a
|
@ -95,10 +95,10 @@ public:
|
||||||
}
|
}
|
||||||
} m_sbuf;
|
} m_sbuf;
|
||||||
PyOutStream(BlenderConnection* parent, bool deleteOnError)
|
PyOutStream(BlenderConnection* parent, bool deleteOnError)
|
||||||
: m_parent(parent),
|
: std::ostream(&m_sbuf),
|
||||||
m_sbuf(*this, deleteOnError),
|
m_parent(parent),
|
||||||
m_deleteOnError(deleteOnError),
|
m_deleteOnError(deleteOnError),
|
||||||
std::ostream(&m_sbuf)
|
m_sbuf(*this, deleteOnError)
|
||||||
{
|
{
|
||||||
m_parent->m_lock = true;
|
m_parent->m_lock = true;
|
||||||
m_parent->_writeLine("PYBEGIN");
|
m_parent->_writeLine("PYBEGIN");
|
||||||
|
@ -110,8 +110,7 @@ public:
|
||||||
public:
|
public:
|
||||||
PyOutStream(const PyOutStream& other) = delete;
|
PyOutStream(const PyOutStream& other) = delete;
|
||||||
PyOutStream(PyOutStream&& other)
|
PyOutStream(PyOutStream&& other)
|
||||||
: m_parent(other.m_parent), m_sbuf(std::move(other.m_sbuf)),
|
: std::ostream(&m_sbuf), m_parent(other.m_parent), m_sbuf(std::move(other.m_sbuf))
|
||||||
std::ostream(&m_sbuf)
|
|
||||||
{other.m_parent = nullptr;}
|
{other.m_parent = nullptr;}
|
||||||
~PyOutStream() {close();}
|
~PyOutStream() {close();}
|
||||||
void close()
|
void close()
|
||||||
|
|
Loading…
Reference in New Issue