From 02717bf8d1ad2d652158808dbea7bbbf9504307c Mon Sep 17 00:00:00 2001 From: Jan Beich Date: Mon, 1 Apr 2024 20:18:18 +0000 Subject: [PATCH] hyprerror: align 32-bit types after 4c796683c05a (#5375) src/hyprerror/HyprError.cpp:64:33: error: no matching function for call to 'min' const auto VISLINECOUNT = std::min(LINECOUNT, *LINELIMIT); ^~~~~~~~ /usr/include/c++/v1/__algorithm/min.h:40:1: note: candidate template ignored: deduced conflicting types for parameter '_Tp' ('int' vs. 'long long') min(const _Tp& __a, const _Tp& __b) ^ /usr/include/c++/v1/__algorithm/min.h:51:1: note: candidate template ignored: could not match 'initializer_list<_Tp>' against 'int' min(initializer_list<_Tp> __t, _Compare __comp) ^ /usr/include/c++/v1/__algorithm/min.h:60:1: note: candidate function template not viable: requires single argument '__t', but 2 arguments were provided min(initializer_list<_Tp> __t) ^ /usr/include/c++/v1/__algorithm/min.h:31:1: note: candidate function template not viable: requires 3 arguments, but 2 were provided min(const _Tp& __a, const _Tp& __b, _Compare __comp) ^ --- src/hyprerror/HyprError.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/hyprerror/HyprError.cpp b/src/hyprerror/HyprError.cpp index 73f9c5d5..de386097 100644 --- a/src/hyprerror/HyprError.cpp +++ b/src/hyprerror/HyprError.cpp @@ -58,7 +58,7 @@ void CHyprError::createQueued() { cairo_paint(CAIRO); cairo_restore(CAIRO); - const auto LINECOUNT = 1 + std::count(m_szQueued.begin(), m_szQueued.end(), '\n'); + const auto LINECOUNT = Hyprlang::INT{1} + std::count(m_szQueued.begin(), m_szQueued.end(), '\n'); static auto LINELIMIT = CConfigValue("debug:error_limit"); const auto VISLINECOUNT = std::min(LINECOUNT, *LINELIMIT);