From d2382e8de91117cae3bbc0b308862d785e66c670 Mon Sep 17 00:00:00 2001 From: gd Date: Sat, 6 Jul 2024 16:20:03 +0300 Subject: [PATCH] ParseStringFilter: when failed to parse the operator, indicate the unknown operator in the error message --- src/song/Filter.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/song/Filter.cxx b/src/song/Filter.cxx index 8f7dbb2c6..6cef1f8b0 100644 --- a/src/song/Filter.cxx +++ b/src/song/Filter.cxx @@ -304,7 +304,7 @@ ParseStringFilter(const char *&s, bool fold_case) if (s[0] == '!' && s[1] == '=') negated = true; else if (s[0] != '=' || s[1] != '=') - throw std::runtime_error("'==' or '!=' expected"); + throw FmtRuntimeError("Unknown filter operator: {}", s); s = StripLeft(s + 2); auto value = ExpectQuoted(s);