We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d9af139 commit e20d2acCopy full SHA for e20d2ac
libmamba/src/specs/match_spec.cpp
@@ -505,9 +505,9 @@ namespace mamba::specs
505
auto MatchSpec::parse(std::string_view str) -> expected_parse_t<MatchSpec>
506
{
507
// Remove comments, i.e. everything after ` #` (space included)
508
- if (const auto idx = str.find('#'); idx != std::string::npos && str[idx - 1] == ' ')
+ if (const auto idx = str.find(" #"); idx != std::string::npos)
509
510
- str = str.substr(0, idx);
+ str = str.substr(0, idx + 1);
511
}
512
513
// Remove trailing whitespaces
0 commit comments