Core/Misc: mark a couple ctors as noexcept to silence warnings

This commit is contained in:
Ovahlord committed 2023-07-16 15:54:24 +02:00
1 parent 929a804052
commit a3c46b7249
2 files changed
+4 -4

No files matched your search

+2 -2
View File
@@ -145,10 +145,10 @@ class TC_GAME_API ObjectGuid
ObjectGuid(HighGuid hi, uint32 entry, uint32 counter) { _data._guid = counter ? uint64(counter) | (uint64(entry) << 32) | (uint64(hi) << ((hi == HighGuid::Corpse || hi == HighGuid::AreaTrigger) ? 48 : 52)) : 0; }
ObjectGuid(HighGuid hi, uint32 counter) { _data._guid = counter ? uint64(counter) | (uint64(hi) << ((hi == HighGuid::Corpse || hi == HighGuid::AreaTrigger) ? 48 : 52)) : 0; }
ObjectGuid(ObjectGuid const& r) : _data(r._data) { }
ObjectGuid(ObjectGuid&& r) : _data(r._data) { }
ObjectGuid(ObjectGuid&& r) noexcept : _data(r._data) { }
ObjectGuid& operator=(ObjectGuid const& r) { _data = r._data; return *this; }
ObjectGuid& operator=(ObjectGuid&& r) { _data = r._data; return *this; }
ObjectGuid& operator=(ObjectGuid&& r) noexcept { _data = r._data; return *this; }
operator uint64() const { return _data._guid; }
PackedGuidReader ReadAsPacked() { return PackedGuidReader(*this); }
+2 -2
View File
@@ -36,7 +36,7 @@ class WorldPacket : public ByteBuffer
WorldPacket(uint16 opcode, size_t res = 200, ConnectionType connection = CONNECTION_TYPE_DEFAULT) : ByteBuffer(res),
m_opcode(opcode), _connection(connection), _compressionStream(nullptr) { }
WorldPacket(WorldPacket&& packet) : ByteBuffer(std::move(packet)), m_opcode(packet.m_opcode), _connection(packet._connection), _compressionStream(nullptr)
WorldPacket(WorldPacket&& packet) noexcept : ByteBuffer(std::move(packet)), m_opcode(packet.m_opcode), _connection(packet._connection), _compressionStream(nullptr)
{
}
@@ -60,7 +60,7 @@ class WorldPacket : public ByteBuffer
return *this;
}
WorldPacket& operator=(WorldPacket&& right)
WorldPacket& operator=(WorldPacket&& right) noexcept
{
if (this != &right)
{