$raw) { if (!str_contains($raw, ',)')) { continue; } // `(,)` is a macro repetition fragment (e.g. `$(,)?`). if (str_contains($raw, '(,)')) { continue; } $errors[] = "{$relative}:" . ($idx + 1) . ': trailing `,)` before a closing paren'; } } return $errors; } }