Skip to content

Commit

Permalink
fix or work around compilation errors
Browse files Browse the repository at this point in the history
It now compiles with gcc13 and QT 5.15

-fpermissive is still necessary though :/
  • Loading branch information
Atemu committed Apr 22, 2024
1 parent a89ef2e commit 099b824
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 10 deletions.
2 changes: 1 addition & 1 deletion src/mod_position_spread.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ enum TALKERS_REGION
TALKERS_REGION_RIGHT,
TALKERS_REGION_END
};
Q_DECLARE_METATYPE(TALKERS_REGION)
Q_DECLARE_METATYPE(thorwe::TALKERS_REGION)

class PositionSpread : public Module_Qt, public TalkInterface
{
Expand Down
18 changes: 10 additions & 8 deletions src/positional_audio/mod_positionalaudio.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -676,7 +676,8 @@ uint64 connection_id, anyID client_id, bool isMe, QString cmd, QTextStream &args

if (args.atEnd()) // Player left vr (unlocked)
{
Log(QString("%1 left %2 VR.").arg(obj->getIdentity()).arg(QString::fromStdWString(obj->get_vr())));
// FIXME error: no matching function for call to 'QString::arg(std::__cxx11::basic_string<wchar_t>&)'
// Log(QString("%1 left %2 VR.").arg(obj->getIdentity()).arg(QString::fromStdWString(obj->get_vr())));
remove_other(connection_id, client_id);
m_PlayersInMyContext.remove(connection_id, client_id);
return true;
Expand Down Expand Up @@ -725,11 +726,12 @@ uint64 connection_id, anyID client_id, bool isMe, QString cmd, QTextStream &args
isDirtyId = (identity != obj->getIdentityRaw());
obj->setIdentityRaw(identity);

Log(QString("Received: VR: %2 CO: %3 ID: %4")
.arg(name)
.arg((context == meObj.get_context()) ? "match" : "no match")
.arg(identity),
connection_id, LogLevel_DEBUG);
// FIXME error: no matching function for call to 'QString::arg(std::__cxx11::basic_string<wchar_t>&)'
// Log(QString("Received: VR: %2 CO: %3 ID: %4")
// .arg(name)
// .arg((context == meObj.get_context()) ? "match" : "no match")
// .arg(identity),
// connection_id, LogLevel_DEBUG);

if (isDirtyName || isDirtyContext)
{
Expand Down Expand Up @@ -782,7 +784,7 @@ auto PositionalAudio::GetSendString(bool isAll) -> QString
if (isAll)
{
// out << " " << m_GameName;
out << " " << meObj.get_vr();
out << " " << QString::fromStdWString(meObj.get_vr());

{
const auto &my_context = meObj.get_context_as_string();
Expand All @@ -793,7 +795,7 @@ auto PositionalAudio::GetSendString(bool isAll) -> QString
<< (my_context.empty() ? "[Ct_None]" : QString::fromStdString(my_context));

if (!my_ident.empty())
out << " " << my_ident;
out << " " << QString::fromStdWString(my_ident);
}
}
}
Expand Down
1 change: 1 addition & 0 deletions src/positional_audio/shared_mem_reader.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#include <gsl/span>

#include <array>
#include <vector>
#include <mutex>
#include <optional>
#include <shared_mutex>
Expand Down

0 comments on commit 099b824

Please sign in to comment.