mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2026-07-30 07:44:13 +02:00
33013477ad
QVector::size() (== QList::size() under Qt6) returns qsizetype (64-bit), while 'level' is a plain int. std::min(level, m_real_terminal.size()-1) therefore tries to deduce a single T from two different argument types, which fails - GCC reports it against the unrelated std::min(initializer_list<T>) overload, but the real issue is the type mismatch between the two-argument candidates. Under Qt5, QVector::size() returned int, so this compiled fine. Force T=int explicitly via std::min<int>(...) and cast size() down to int (physical terminal counts are always tiny), matching the pattern already used safely elsewhere in the codebase (e.g. qetgraphicstableitem.cpp).