Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 13 for KindString (0.31 sec)

  1. src/log/slog/value.go

    // The zero Value corresponds to nil.
    type Value struct {
    	_ [0]func() // disallow ==
    	// num holds the value for Kinds Int64, Uint64, Float64, Bool and Duration,
    	// the string length for KindString, and nanoseconds since the epoch for KindTime.
    	num uint64
    	// If any is of type Kind, then the value is in num as described above.
    	// If any is of type *time.Location, then the Kind is Time and time.Time value
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 16 16:12:08 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  2. api/go1.21.txt

    pkg log/slog, const KindInt64 = 4 #56345
    pkg log/slog, const KindInt64 Kind #56345
    pkg log/slog, const KindLogValuer = 9 #56345
    pkg log/slog, const KindLogValuer Kind #56345
    pkg log/slog, const KindString = 5 #56345
    pkg log/slog, const KindString Kind #56345
    pkg log/slog, const KindTime = 6 #56345
    pkg log/slog, const KindTime Kind #56345
    pkg log/slog, const KindUint64 = 7 #56345
    pkg log/slog, const KindUint64 Kind #56345
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Aug 07 09:39:17 UTC 2023
    - 25.6K bytes
    - Viewed (0)
  3. src/regexp/example_test.go

    	// Output:
    	// true
    	// false
    }
    
    func ExampleRegexp_FindString() {
    	re := regexp.MustCompile(`foo.?`)
    	fmt.Printf("%q\n", re.FindString("seafood fool"))
    	fmt.Printf("%q\n", re.FindString("meat"))
    	// Output:
    	// "food"
    	// ""
    }
    
    func ExampleRegexp_FindStringIndex() {
    	re := regexp.MustCompile(`ab?`)
    	fmt.Println(re.FindStringIndex("tablett"))
    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/cmd/go/internal/work/security.go

    		arg := list[i]
    		if disallow != nil && disallow.FindString(arg) == arg {
    			goto Bad
    		}
    		if allow != nil && allow.FindString(arg) == arg {
    			continue Args
    		}
    		for _, re := range invalid {
    			if re.FindString(arg) == arg { // must be complete match
    				goto Bad
    			}
    		}
    		for _, re := range valid {
    			if re.FindString(arg) == arg { // must be complete match
    				continue Args
    			}
    		}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 20 15:47:34 UTC 2024
    - 10K bytes
    - Viewed (0)
  5. src/cmd/vendor/github.com/google/pprof/internal/driver/interactive.go

    	cmd, args := input[:1], input[1:]
    	name := cmd[0]
    
    	c := pprofCommands[name]
    	if c == nil {
    		// Attempt splitting digits on abbreviated commands (eg top10)
    		if d := tailDigitsRE.FindString(name); d != "" && d != name {
    			name = name[:len(name)-len(d)]
    			cmd[0], args = name, append([]string{d}, args...)
    			c = pprofCommands[name]
    		}
    	}
    	if c == nil {
    		if _, ok := configHelp[name]; ok {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Nov 22 18:58:12 UTC 2022
    - 10.6K bytes
    - Viewed (0)
  6. src/regexp/exec_test.go

    	{"32M", 32 << 20},
    }
    
    func TestLongest(t *testing.T) {
    	re, err := Compile(`a(|b)`)
    	if err != nil {
    		t.Fatal(err)
    	}
    	if g, w := re.FindString("ab"), "a"; g != w {
    		t.Errorf("first match was %q, want %q", g, w)
    	}
    	re.Longest()
    	if g, w := re.FindString("ab"), "ab"; g != w {
    		t.Errorf("longest match was %q, want %q", g, w)
    	}
    }
    
    // TestProgramTooLongForBacktrack tests that a regex which is too long
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 25 19:36:03 UTC 2024
    - 20.7K bytes
    - Viewed (0)
  7. operator/pkg/validate/common.go

    )
    
    // validateWithRegex checks whether the given value matches the regexp r.
    func validateWithRegex(path util.Path, val any, r *regexp.Regexp) (errs util.Errors) {
    	valStr := fmt.Sprint(val)
    	if len(r.FindString(valStr)) != len(valStr) {
    		errs = util.AppendErr(errs, fmt.Errorf("invalid value %s: %v", path, val))
    		printError(errs.ToError())
    	}
    	return errs
    }
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu Aug 10 15:35:03 UTC 2023
    - 11K bytes
    - Viewed (0)
  8. src/regexp/all_test.go

    	b.StopTimer()
    	re := MustCompile("a+b+")
    	wantSubs := "aaabb"
    	s := "acbb" + wantSubs + "dd"
    	b.StartTimer()
    	b.ReportAllocs()
    	for i := 0; i < b.N; i++ {
    		subs := re.FindString(s)
    		if subs != wantSubs {
    			b.Fatalf("FindString(%q) = %q; want %q", s, subs, wantSubs)
    		}
    	}
    }
    
    func BenchmarkFindSubmatch(b *testing.B) {
    	b.StopTimer()
    	re := MustCompile("a(a+b+)b")
    	wantSubs := "aaabb"
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 25 19:36:03 UTC 2024
    - 25.8K bytes
    - Viewed (0)
  9. src/regexp/regexp.go

    // A return value of nil indicates no match.
    func (re *Regexp) FindIndex(b []byte) (loc []int) {
    	a := re.doExecute(nil, b, "", 0, 2, nil)
    	if a == nil {
    		return nil
    	}
    	return a[0:2]
    }
    
    // FindString returns a string holding the text of the leftmost match in s of the regular
    // expression. If there is no match, the return value is an empty string,
    // but it will also be empty if the regular expression successfully matches
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Feb 26 20:50:01 UTC 2024
    - 38.5K bytes
    - Viewed (0)
  10. src/regexp/find_test.go

    				t.Errorf("expected %q got %q: %s", expect, result, test)
    			}
    		}
    	}
    }
    
    func TestFindString(t *testing.T) {
    	for _, test := range findTests {
    		result := MustCompile(test.pat).FindString(test.text)
    		switch {
    		case len(test.matches) == 0 && len(result) == 0:
    			// ok
    		case test.matches == nil && result != "":
    			t.Errorf("expected no match; got one: %s", test)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Oct 11 15:28:50 UTC 2021
    - 16.3K bytes
    - Viewed (0)
Back to top