From 6682cf749f67a974eba4a2904af10ba63630fc35 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Mon, 5 Oct 2020 21:13:56 +0200 Subject: [PATCH] playlist/cue/parser: use lambda to fix ambiguous overload On Windows, there is an IsWhitespaceOrNull() overload with TCHAR, and the compiler doesn't know which one to pass to std::find_if(). --- src/playlist/cue/CueParser.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/playlist/cue/CueParser.cxx b/src/playlist/cue/CueParser.cxx index fd10586ca..7133c9149 100644 --- a/src/playlist/cue/CueParser.cxx +++ b/src/playlist/cue/CueParser.cxx @@ -32,7 +32,7 @@ cue_next_word(StringView &src) noexcept assert(!IsWhitespaceNotNull(src.front())); auto end = std::find_if(src.begin(), src.end(), - IsWhitespaceOrNull); + [](char ch){ return IsWhitespaceOrNull(ch); }); StringView word(src.begin(), end); src = src.substr(end); return word;