Repository navigation
Match the empty remainder with a trailing whole-segment ** [patch] - #192
matt-edmondson wants to merge 2 commits into
Conversation
ExpandGlobStarSegments only rewrote a "**" followed by a separator, so a trailing "**" (as in "src/**") reached DotNet.Glob as "**" joined to the masked separator, which needs at least one more character. "src/**" then missed "src/" though "src/*" matched it, and "-build/**" left "build/" visible. A trailing "**" that starts the token or follows a separator is now written as "*", which already crosses the masked separator and also matches nothing. Fixes #191 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017vfJW3JF2xHwwm6qrw3Bh7
…patch] The README API test required every overload's same-named parameter to carry the documented default. The binary-compatibility overloads from #166 have no defaults by design, so main has been red since #178. They are marked [EditorBrowsable(Never)] and are not what the README documents, so the default check now skips them. A wrong default on a visible overload still fails. Fixes #183 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017vfJW6FzBtSrY5LKUuDYce
|
Open PR #186 already fixes it, so I cherry-picked its one commit, which changes only Generated by Claude Code |
|
|
This diff's only own findings are three INFO-level MSTEST0068 hints in the new test (prefer Generated by Claude Code |




Fixes #191
What was wrong
ExpandGlobStarSegmentsonly rewrote a**followed by a separator. A trailing**, as insrc/**, reached DotNet.Glob unchanged. Once the separator was masked, DotNet.Glob read it as**joined to a literal, and that form needs at least one more character. As a result:src/**missedsrc/, thoughsrc/*matched it.-build/**leftbuild/visible.a/**/b/**misseda/b/, and/**missed/.Change
After the
**/expansion, a trailing**that starts the token or follows a separator is written as*. Under the masked semantics*already crosses separators, so the pattern still matches deeper paths and now also matches the empty remainder.A
**joined to a literal (foo**) or to another*is left as it was. That case is #135.This branch also carries #186's one commit, which changes only
ReadmeTests.cs. It fixesEveryMethodInTheReadmeApiReferenceExistsWithItsDocumentedDefaults, a test that already fails onmain, so CI here can go green before #186 merges. If #186 merges first, that change drops out of the squash.Tests
TrailingGlobStarSegmentMatchesTheEmptyRemaindercovers the issue's cases and the fuzzer's (*/**,?/**,b-/**), plus a backslash separator. Each runs underByWholeStringand under the default options.TrailingGlobStarSegmentStillNeedsItsDirectorychecks thatsrc/**still rejectssrcanddocs/a.cs, andfoo**still rejectsfoo.TrailingGlobStarSegmentFiltersLikeASingleStarcovers the issue'sFilterrepro:src/**returnssrc/,src/a.csandsrc/lib/b.cs, the same assrc/*.-build/**hidesbuild/.TextFilter.cschange reverted, all 8 new positive cases fail. With it, the full suite passes: 281/281 locally and on the ubuntu, windows and macos CI legs.🤖 Generated with Claude Code
https://claude.ai/code/session_017vfJW3JF2xHwwm6qrw3Bh7