it dont compile
binex-dsk opened this issue · comments
Operating System
No response
Version of PolyMC
polymc-git
Version of Qt
qt 6.6.0
Description of bug
/home/swurl/.cache/yay/polymc-git/src/PolyMC/launcher/translations/TranslationsModel.cpp: In member function ‘Language* TranslationsModel::findLanguage(const QString&)’:
/home/swurl/.cache/yay/polymc-git/src/PolyMC/launcher/translations/TranslationsModel.cpp:503:16: error: cannot convert ‘QList::iterator’ to ‘Language*’ in return
503 | return found;
| ^~~~~
| |
| QList::iterator
/home/swurl/.cache/yay/polymc-git/src/PolyMC/launcher/translations/TranslationsModel.cpp: In member function ‘QModelIndex TranslationsModel::selectedIndex()’:
/home/swurl/.cache/yay/polymc-git/src/PolyMC/launcher/translations/TranslationsModel.cpp:634:28: error: no match for ‘operator-’ (operand types are ‘Language*’ and ‘QList::iterator’)
634 | return index(found - d->m_languages.begin(), 0, QModelIndex());
| ~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~
| | |
| Language* QList::iterator
Steps to reproduce
/home/swurl/.cache/yay/polymc-git/src/PolyMC/launcher/translations/TranslationsModel.cpp: In member function ‘Language* TranslationsModel::findLanguage(const QString&)’:
/home/swurl/.cache/yay/polymc-git/src/PolyMC/launcher/translations/TranslationsModel.cpp:503:16: error: cannot convert ‘QList::iterator’ to ‘Language*’ in return
503 | return found;
| ^~~~~
| |
| QList::iterator
/home/swurl/.cache/yay/polymc-git/src/PolyMC/launcher/translations/TranslationsModel.cpp: In member function ‘QModelIndex TranslationsModel::selectedIndex()’:
/home/swurl/.cache/yay/polymc-git/src/PolyMC/launcher/translations/TranslationsModel.cpp:634:28: error: no match for ‘operator-’ (operand types are ‘Language*’ and ‘QList::iterator’)
634 | return index(found - d->m_languages.begin(), 0, QModelIndex());
| ~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~
| | |
| Language* QList::iterator
Suspected cause
/home/swurl/.cache/yay/polymc-git/src/PolyMC/launcher/translations/TranslationsModel.cpp: In member function ‘Language* TranslationsModel::findLanguage(const QString&)’:
/home/swurl/.cache/yay/polymc-git/src/PolyMC/launcher/translations/TranslationsModel.cpp:503:16: error: cannot convert ‘QList::iterator’ to ‘Language*’ in return
503 | return found;
| ^~~~~
| |
| QList::iterator
/home/swurl/.cache/yay/polymc-git/src/PolyMC/launcher/translations/TranslationsModel.cpp: In member function ‘QModelIndex TranslationsModel::selectedIndex()’:
/home/swurl/.cache/yay/polymc-git/src/PolyMC/launcher/translations/TranslationsModel.cpp:634:28: error: no match for ‘operator-’ (operand types are ‘Language*’ and ‘QList::iterator’)
634 | return index(found - d->m_languages.begin(), 0, QModelIndex());
| ~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~
| | |
| Language* QList::iterator
This issue is unique
- I have searched the issue tracker and did not find an issue describing my bug.