Skip to content

Commit

Permalink
Drop qAsConst (#1119)
Browse files Browse the repository at this point in the history
Prefer C++17 std::as_const().
The one that got away!
  • Loading branch information
luis-pereira authored May 3, 2024
1 parent 78ace6d commit ff241f9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>. *
***************************************************************************/

#include <utility>

#include <QDockWidget>
#include <QScreen>
#include <QToolButton>
Expand Down Expand Up @@ -537,7 +539,7 @@ void MainWindow::setupCustomDirs()

dirs.removeDuplicates(); // QStandardPaths::locateAll() produces duplicates

for (const QString& dir : qAsConst(dirs)) {
for (const QString& dir : std::as_const(dirs)) {
TermWidgetImpl::addCustomColorSchemeDir(dir + QLatin1String("/color-schemes"));
}
// FIXME: To be deprecated and then removed
Expand Down

0 comments on commit ff241f9

Please sign in to comment.