Remove the Go implementation; build and release the Rust version for every OS #2

Merged
andydixon merged 12 commits from rust-port into master 2026-10-08 22:25:29 +02:00
Showing only changes of commit b21bcedba0 - Show all commits
+3 -3
View File
@@ -321,13 +321,13 @@ pub(super) fn name_match(v: &str) -> Expr {
/// Reports whether pattern is a well-formed glob (see
/// `platform::glob_match`): every `[` class is closed and non-empty, ranges
/// have both ends, and no escape is dangling.
/// have both ends, and (on Unix, where `\` escapes) no escape is dangling.
fn glob_ok(p: &[u8]) -> bool {
// One possibly escaped character of a range; None if malformed.
let esc = |mut i: usize| -> Option<usize> {
match p.get(i)? {
b'-' | b']' => return None,
b'\\' => {
b'\\' if cfg!(unix) => {
i += 1;
p.get(i)?;
}
@@ -338,7 +338,7 @@ fn glob_ok(p: &[u8]) -> bool {
let mut i = 0;
while i < p.len() {
match p[i] {
b'\\' => {
b'\\' if cfg!(unix) => {
if i + 1 >= p.len() {
return false;
}