mirror of
https://github.com/octoleo/syncthing.git
synced 2025-01-22 22:58:25 +00:00
vendor: Update github.com/gobwas/glob (bugfix)
This commit is contained in:
parent
8ce9b026e9
commit
a7f7058636
7
vendor/github.com/gobwas/glob/compiler/compiler.go
generated
vendored
7
vendor/github.com/gobwas/glob/compiler/compiler.go
generated
vendored
@ -5,10 +5,11 @@ package compiler
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"reflect"
|
||||||
|
|
||||||
"github.com/gobwas/glob/match"
|
"github.com/gobwas/glob/match"
|
||||||
"github.com/gobwas/glob/syntax/ast"
|
"github.com/gobwas/glob/syntax/ast"
|
||||||
"github.com/gobwas/glob/util/runes"
|
"github.com/gobwas/glob/util/runes"
|
||||||
"reflect"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func optimizeMatcher(matcher match.Matcher) match.Matcher {
|
func optimizeMatcher(matcher match.Matcher) match.Matcher {
|
||||||
@ -373,11 +374,11 @@ func commonChildren(nodes []*ast.Node) (commonLeft, commonRight []*ast.Node) {
|
|||||||
breakRight bool
|
breakRight bool
|
||||||
commonTotal int
|
commonTotal int
|
||||||
)
|
)
|
||||||
for i, j := 0, treeLength-1; commonTotal < treeLength && j >= 0 && !(breakLeft && breakLeft); i, j = i+1, j-1 {
|
for i, j := 0, treeLength-1; commonTotal < treeLength && j >= 0 && !(breakLeft && breakRight); i, j = i+1, j-1 {
|
||||||
treeLeft := tree.Children[i]
|
treeLeft := tree.Children[i]
|
||||||
treeRight := tree.Children[j]
|
treeRight := tree.Children[j]
|
||||||
|
|
||||||
for k := 0; k < len(nodes) && !(breakLeft && breakLeft); k++ {
|
for k := 0; k < len(nodes) && !(breakLeft && breakRight); k++ {
|
||||||
// skip least children node
|
// skip least children node
|
||||||
if k == idx {
|
if k == idx {
|
||||||
continue
|
continue
|
||||||
|
4
vendor/manifest
vendored
4
vendor/manifest
vendored
@ -140,8 +140,8 @@
|
|||||||
{
|
{
|
||||||
"importpath": "github.com/gobwas/glob",
|
"importpath": "github.com/gobwas/glob",
|
||||||
"repository": "https://github.com/gobwas/glob",
|
"repository": "https://github.com/gobwas/glob",
|
||||||
"vcs": "",
|
"vcs": "git",
|
||||||
"revision": "0354991b92587e2742549d3036f3b5bae5ab03f2",
|
"revision": "bea32b9cd2d6f55753d94a28e959b13f0244797a",
|
||||||
"branch": "master"
|
"branch": "master"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user