Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 337 for NegExp (0.24 sec)

  1. src/regexp/regexp.go

    	} else {
    		regexp.prefix, regexp.prefixComplete, regexp.prefixEnd = onePassPrefix(prog)
    	}
    	if regexp.prefix != "" {
    		// TODO(rsc): Remove this allocation by adding
    		// IndexString to package bytes.
    		regexp.prefixBytes = []byte(regexp.prefix)
    		regexp.prefixRune, _ = utf8.DecodeRuneInString(regexp.prefix)
    	}
    
    	n := len(prog.Inst)
    	i := 0
    	for matchSize[i] != 0 && matchSize[i] < n {
    		i++
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Feb 26 20:50:01 UTC 2024
    - 38.5K bytes
    - Viewed (0)
  2. src/regexp/syntax/regexp.go

    package syntax
    
    // Note to implementers:
    // In this package, re is always a *Regexp and r is always a rune.
    
    import (
    	"slices"
    	"strconv"
    	"strings"
    	"unicode"
    )
    
    // A Regexp is a node in a regular expression syntax tree.
    type Regexp struct {
    	Op       Op // operator
    	Flags    Flags
    	Sub      []*Regexp  // subexpressions, if any
    	Sub0     [1]*Regexp // storage for short Sub
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Mar 29 16:41:51 UTC 2024
    - 11.6K bytes
    - Viewed (0)
  3. src/regexp/example_test.go

    	fmt.Println(matched, err)
    	matched, err = regexp.MatchString(`bar.*`, "seafood")
    	fmt.Println(matched, err)
    	matched, err = regexp.MatchString(`a(b`, "seafood")
    	fmt.Println(matched, err)
    	// Output:
    	// true <nil>
    	// false <nil>
    	// false error parsing regexp: missing closing ): `a(b`
    }
    
    func ExampleQuoteMeta() {
    	fmt.Println(regexp.QuoteMeta(`Escaping symbols like: .+*?()|[]{}^$`))
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Aug 07 00:22:53 UTC 2023
    - 11.1K bytes
    - Viewed (0)
  4. src/regexp/syntax/parse_test.go

    			t.Errorf("Parse(%#q, Perl): %v", regexp, err)
    		}
    		if re, err := Parse(regexp, POSIX); err == nil {
    			t.Errorf("Parse(%#q, POSIX) = %s, should have failed", regexp, dump(re))
    		}
    	}
    	for _, regexp := range onlyPOSIX {
    		if re, err := Parse(regexp, Perl); err == nil {
    			t.Errorf("Parse(%#q, Perl) = %s, should have failed", regexp, dump(re))
    		}
    		if _, err := Parse(regexp, POSIX); err != nil {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Aug 16 16:02:30 UTC 2023
    - 16.2K bytes
    - Viewed (0)
  5. istioctl/pkg/dashboard/dashboard_test.go

    			WantException:  false,
    		},
    		{ // case 4
    			Args:           strings.Split("envoy --browser=false", " "),
    			ExpectedRegexp: regexp.MustCompile(".*Error: specify a pod or --selector"),
    			WantException:  true,
    		},
    		{ // case 5
    			Args:           strings.Split("envoy --browser=false pod-123456-7890", " "),
    			ExpectedRegexp: regexp.MustCompile("http://localhost:3456"),
    			WantException:  false,
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Nov 21 01:17:24 UTC 2023
    - 4.3K bytes
    - Viewed (0)
  6. operator/pkg/validate/common.go

    // matches.
    func repeated(res ...*regexp.Regexp) *regexp.Regexp {
    	return match(group(expression(res...)).String() + `+`)
    }
    
    // group wraps the regexp in a non-capturing group.
    func group(res ...*regexp.Regexp) *regexp.Regexp {
    	return match(`(?:` + expression(res...).String() + `)`)
    }
    
    // capture wraps the expression in a capturing group.
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu Aug 10 15:35:03 UTC 2023
    - 11K bytes
    - Viewed (0)
  7. src/cmd/vendor/github.com/google/pprof/internal/binutils/disasm.go

    package binutils
    
    import (
    	"bytes"
    	"io"
    	"regexp"
    	"strconv"
    	"strings"
    
    	"github.com/google/pprof/internal/plugin"
    	"github.com/ianlancetaylor/demangle"
    )
    
    var (
    	nmOutputRE                = regexp.MustCompile(`^\s*([[:xdigit:]]+)\s+(.)\s+(.*)`)
    	objdumpAsmOutputRE        = regexp.MustCompile(`^\s*([[:xdigit:]]+):\s+(.*)`)
    	objdumpOutputFileLine     = regexp.MustCompile(`^;?\s?(.*):([0-9]+)`)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Aug 15 16:39:48 UTC 2023
    - 5.2K bytes
    - Viewed (0)
  8. tests/table_test.go

    	if !regexp.MustCompile("SELECT \\* FROM `user`").MatchString(r.Statement.SQL.String()) {
    		t.Errorf("Table with escape character, got %v", r.Statement.SQL.String())
    	}
    
    	r = dryDB.Table("user as u").Select("name").Find(&User{}).Statement
    	if !regexp.MustCompile("SELECT .name. FROM user as u WHERE .u.\\..deleted_at. IS NULL").MatchString(r.Statement.SQL.String()) {
    Registered: Wed Jun 12 16:27:09 UTC 2024
    - Last Modified: Sat Mar 09 09:31:28 UTC 2024
    - 10.6K bytes
    - Viewed (0)
  9. src/cmd/covdata/tool_test.go

    	testpoints := []struct {
    		tag string
    		re  *regexp.Regexp
    	}{
    		{
    			"args",
    			regexp.MustCompile(`^data file .+ GOOS=.+ GOARCH=.+ program args: .+$`),
    		},
    		{
    			"main package",
    			regexp.MustCompile(`^Package path: ` + mainPkgPath + `\s*$`),
    		},
    		{
    			"main function",
    			regexp.MustCompile(`^Func: main\s*$`),
    		},
    	}
    
    	bad := false
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 07 20:46:32 UTC 2024
    - 24.5K bytes
    - Viewed (0)
  10. src/cmd/cgo/internal/testerrors/errors_test.go

    			t.Fatal(err)
    		}
    		var errors []*regexp.Regexp
    		for i, line := range bytes.Split(contents, []byte("\n")) {
    			if bytes.HasSuffix(line, []byte("ERROR HERE")) {
    				re := regexp.MustCompile(regexp.QuoteMeta(fmt.Sprintf("%s:%d:", file, i+1)))
    				errors = append(errors, re)
    				continue
    			}
    
    			if _, frag, ok := bytes.Cut(line, []byte("ERROR HERE: ")); ok {
    				re, err := regexp.Compile(fmt.Sprintf(":%d:.*%s", i+1, frag))
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 20 15:50:06 UTC 2024
    - 4K bytes
    - Viewed (0)
Back to top