-
Notifications
You must be signed in to change notification settings - Fork 452
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Qt6 issue with sdrbase/util/baudot.cpp #1713
Comments
PS. Same issue in rttydemodsink.cpp(520,20): error: use of overloaded operator '!=' is ambiguous (with operand types 'QString' and 'char')
if ((c != '\0') && (c != '<') && (c != '>') && (c != '^'))
~ ^ ~~~~
f:\gv\Qt\6.2.4\msvc2019_64\include\QtCore/qstring.h(903,17): note: candidate function
friend bool operator!=(const QString &s1, std::nullptr_t) noexcept { return !s1.isEmpty(); }
^
f:\gv\Qt\6.2.4\msvc2019_64\include\QtCore/qstring.h(916,17): note: candidate function
friend bool operator!=(const QString &s1, const char16_t *s2) noexcept { return s1 != QStringView(s2); }
^
f:\gv\Qt\6.2.4\msvc2019_64\include\QtCore/qstring.h(1358,22): note: candidate function
inline bool QString::operator!=(const char *s) const
^
1 error generated. |
I can understand the compiler may get confused. If I am not mistaken "c" is just a single character. What happens if we use a QChar instead of a QString? |
c can be a string in some of the more obscure character sets (for representing fractions). Comparing against "\0" is fin But I would say stick to Qt 5 on Windows, and if you must use 6, don't use Qt 6.2 - use 6.4 (It will be worse than 5 whatever version of 6 you use - for now). |
While compiling
sdrbase/util/baudot.cpp
using Qt 6.2.4, I'm getting this compile error from clang-cl (ver 16.0.0):Similar from
cl
.I'm not sure why, but I tried this patch in the hope it's logically similar:
With this it compiles with both Qt 5 and 6. But I'm not sure what the test should do.
The text was updated successfully, but these errors were encountered: