- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 371 for rune (0.11 sec)
-
src/bytes/bytes.go
// returning nil instead of empty slice if all spaces. return nil } return s[start:stop] } // Runes interprets s as a sequence of UTF-8-encoded code points. // It returns a slice of runes (Unicode code points) equivalent to s. func Runes(s []byte) []rune { t := make([]rune, utf8.RuneCount(s)) i := 0 for len(s) > 0 { r, l := utf8.DecodeRune(s) t[i] = r i++ s = s[l:] }
Registered: Tue Nov 05 11:13:11 UTC 2024 - Last Modified: Tue Sep 03 20:55:15 UTC 2024 - 35.6K bytes - Viewed (0) -
src/bytes/bytes_test.go
} } func bmIndexRuneUnicode(rt *unicode.RangeTable, needle rune) func(b *testing.B, n int) { var rs []rune for _, r16 := range rt.R16 { for r := rune(r16.Lo); r <= rune(r16.Hi); r += rune(r16.Stride) { if r != needle { rs = append(rs, rune(r)) } } } for _, r32 := range rt.R32 { for r := rune(r32.Lo); r <= rune(r32.Hi); r += rune(r32.Stride) { if r != needle { rs = append(rs, rune(r))
Registered: Tue Nov 05 11:13:11 UTC 2024 - Last Modified: Mon Aug 19 19:09:04 UTC 2024 - 61.2K bytes - Viewed (0) -
internal/s3select/jstream/scratch.go
} // append single byte to scratch buffer func (s *scratch) add(c byte) { if s.fill+1 >= cap(s.data) { s.grow() } s.data[s.fill] = c s.fill++ } // append encoded rune to scratch buffer func (s *scratch) addRune(r rune) int { if s.fill+utf8.UTFMax >= cap(s.data) { s.grow() } n := utf8.EncodeRune(s.data[s.fill:], r) s.fill += n return n
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Sep 23 19:35:41 UTC 2024 - 758 bytes - Viewed (0) -
src/bytes/iter.go
// Unicode code points satisfying f(c). // The iterator yields the same strings that would be returned by FieldsFunc(s), // but without constructing the slice. func FieldsFuncSeq(s []byte, f func(rune) bool) iter.Seq[[]byte] { return func(yield func([]byte) bool) { start := -1 for i := 0; i < len(s); { size := 1 r := rune(s[i]) if r >= utf8.RuneSelf {
Registered: Tue Nov 05 11:13:11 UTC 2024 - Last Modified: Wed Aug 14 18:23:13 UTC 2024 - 3.7K bytes - Viewed (0) -
src/bytes/reader.go
r.i-- return nil } // ReadRune implements the [io.RuneReader] interface. func (r *Reader) ReadRune() (ch rune, size int, err error) { if r.i >= int64(len(r.s)) { r.prevRune = -1 return 0, 0, io.EOF } r.prevRune = int(r.i) if c := r.s[r.i]; c < utf8.RuneSelf { r.i++ return rune(c), 1, nil } ch, size = utf8.DecodeRune(r.s[r.i:]) r.i += int64(size) return }
Registered: Tue Nov 05 11:13:11 UTC 2024 - Last Modified: Tue Jul 16 18:17:37 UTC 2024 - 3.9K bytes - Viewed (0) -
istioctl/pkg/proxyconfig/proxyconfig.go
if (len(args) == 1) != (configDumpFile == "") { cmd.Println(cmd.UsageString()) return fmt.Errorf("cluster requires pod name or --file parameter") } return nil }, RunE: func(c *cobra.Command, args []string) error { kubeClient, err := ctx.CLIClient() if err != nil { return err } var configWriter *configdump.ConfigWriter if len(args) == 1 {
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Thu Oct 24 15:53:49 UTC 2024 - 50.6K bytes - Viewed (0) -
src/bytes/buffer.go
// converted to int they correspond to the rune size that was read. type readOp int8 // Don't use iota for these, as the values need to correspond with the // names and comments, which is easier to see when being explicit. const ( opRead readOp = -1 // Any other read operation. opInvalid readOp = 0 // Non-read operation. opReadRune1 readOp = 1 // Read rune of size 1. opReadRune2 readOp = 2 // Read rune of size 2.
Registered: Tue Nov 05 11:13:11 UTC 2024 - Last Modified: Tue Oct 29 16:47:05 UTC 2024 - 15.7K bytes - Viewed (0) -
src/bytes/example_test.go
fmt.Println(bytes.LastIndexFunc([]byte("go gopher!"), unicode.IsNumber)) // Output: // 8 // 9 // -1 } func ExampleMap() { rot13 := func(r rune) rune { switch { case r >= 'A' && r <= 'Z': return 'A' + (r-'A'+13)%26 case r >= 'a' && r <= 'z': return 'a' + (r-'a'+13)%26 } return r }
Registered: Tue Nov 05 11:13:11 UTC 2024 - Last Modified: Wed Aug 07 17:22:36 UTC 2024 - 14.9K bytes - Viewed (0) -
istioctl/pkg/waypoint/waypoint.go
istioctl waypoint status --namespace default`, Args: func(cmd *cobra.Command, args []string) error { if len(args) != 0 { return fmt.Errorf("unknown subcommand %q", args[0]) } return nil }, RunE: func(cmd *cobra.Command, args []string) error { kubeClient, err := ctx.CLIClient() if err != nil { return fmt.Errorf("failed to create Kubernetes client: %v", err) }
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Wed Oct 09 16:05:45 UTC 2024 - 19.6K bytes - Viewed (0) -
istioctl/pkg/ztunnelconfig/ztunnelconfig.go
istioctl ztunnel-config certificates <ztunnel-name[.namespace]> -o json `, Aliases: []string{"certificates", "certs", "cert"}, Args: common.validateArgs, RunE: runConfigDump(ctx, common, func(cw *ztunnelDump.ConfigWriter) error { switch common.outputFormat { case summaryOutput: return cw.PrintSecretSummary() case jsonOutput, yamlOutput:
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Wed Oct 09 19:17:45 UTC 2024 - 22.2K bytes - Viewed (0)