Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 530 for rune1 (0.22 sec)

  1. src/html/template/html.go

    	// Treated as a quoting character by IE.
    	'`': "`",
    }
    
    // htmlReplacer returns s with runes replaced according to replacementTable
    // and when badRunes is true, certain bad runes are allowed through unescaped.
    func htmlReplacer(s string, replacementTable []string, badRunes bool) string {
    	written, b := 0, new(strings.Builder)
    	r, w := rune(0), 0
    	for i := 0; i < len(s); i += w {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 02 19:42:28 UTC 2023
    - 7.3K bytes
    - Viewed (0)
  2. src/strconv/quote_test.go

    	{string(rune(14)), false},
    	{string(rune(15)), false},
    	{string(rune(16)), false},
    	{string(rune(17)), false},
    	{string(rune(18)), false},
    	{string(rune(19)), false},
    	{string(rune(20)), false},
    	{string(rune(21)), false},
    	{string(rune(22)), false},
    	{string(rune(23)), false},
    	{string(rune(24)), false},
    	{string(rune(25)), false},
    	{string(rune(26)), false},
    	{string(rune(27)), false},
    	{string(rune(28)), false},
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 31 20:37:15 UTC 2022
    - 9.6K bytes
    - Viewed (0)
  3. src/runtime/string_test.go

    }
    
    var sinkInt int
    
    func BenchmarkRuneCount(b *testing.B) {
    	// Each sub-benchmark counts the runes in a string in a different way.
    	b.Run("lenruneslice", func(b *testing.B) {
    		for _, sd := range stringdata {
    			b.Run(sd.name, func(b *testing.B) {
    				for i := 0; i < b.N; i++ {
    					sinkInt += len([]rune(sd.data))
    				}
    			})
    		}
    	})
    	b.Run("rangeloop", func(b *testing.B) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Dec 13 14:05:23 UTC 2022
    - 13.3K bytes
    - Viewed (0)
  4. src/vendor/golang.org/x/text/unicode/norm/normalize.go

    			ss = 0
    			continue
    		}
    		info := f.info(src, i)
    		if info.size == 0 {
    			if atEOF {
    				// include incomplete runes
    				return n, true
    			}
    			return lastSegStart, true
    		}
    		// This block needs to be before the next, because it is possible to
    		// have an overflow for runes that are starters (e.g. with U+FF9E).
    		switch ss.next(info) {
    		case ssStarter:
    			lastSegStart = i
    		case ssOverflow:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 16 22:26:23 UTC 2022
    - 14.9K bytes
    - Viewed (0)
  5. src/cmd/vendor/golang.org/x/build/relnote/links.go

    	}
    	// The open bracket must be preceeded by a link-adjacent rune (or by nothing).
    	if t := plainText(i - 1); t != "" {
    		r, _ := utf8.DecodeLastRuneInString(t)
    		if !isLinkAdjacentRune(r) {
    			return ""
    		}
    	}
    	// The element after the next must be a ']'.
    	if plainText(i+2) != "]" {
    		return ""
    	}
    	// The ']' must be followed by a link-adjacent rune (or by nothing).
    	if t := plainText(i + 3); t != "" {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 04 16:19:04 UTC 2024
    - 8.2K bytes
    - Viewed (0)
  6. src/cmd/compile/internal/types/universe.go

    	}
    
    	// We create separate byte and rune types for better error messages
    	// rather than just creating type alias *Sym's for the uint8 and
    	// int32  Hence, (bytetype|runtype).Sym.isAlias() is false.
    	// TODO(gri) Should we get rid of this special case (at the cost
    	// of less informative error messages involving bytes and runes)?
    	// NOTE(rsc): No, the error message quality is important.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Jan 26 21:56:49 UTC 2023
    - 4K bytes
    - Viewed (0)
  7. src/bytes/bytes_test.go

    			t.Errorf("%s(%q) = %q; want %q", funcName, tc.in, actual, tc.out)
    		}
    	}
    }
    
    func tenRunes(r rune) string {
    	runes := make([]rune, 10)
    	for i := range runes {
    		runes[i] = r
    	}
    	return string(runes)
    }
    
    // User-defined self-inverse mapping function
    func rot13(r rune) rune {
    	const step = 13
    	if r >= 'a' && r <= 'z' {
    		return ((r - 'a' + step) % 26) + 'a'
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 03 12:58:37 UTC 2024
    - 56.5K bytes
    - Viewed (0)
  8. src/cmd/vendor/golang.org/x/text/unicode/norm/normalize.go

    			ss = 0
    			continue
    		}
    		info := f.info(src, i)
    		if info.size == 0 {
    			if atEOF {
    				// include incomplete runes
    				return n, true
    			}
    			return lastSegStart, true
    		}
    		// This block needs to be before the next, because it is possible to
    		// have an overflow for runes that are starters (e.g. with U+FF9E).
    		switch ss.next(info) {
    		case ssStarter:
    			lastSegStart = i
    		case ssOverflow:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jan 24 13:01:26 UTC 2024
    - 14.9K bytes
    - Viewed (0)
  9. src/cmd/vendor/golang.org/x/text/cases/map.go

    // A mapFunc takes a context set to the current rune and writes the mapped
    // version to the same context. It may advance the context to the next rune. It
    // returns whether a checkpoint is possible: whether the pDst bytes written to
    // dst so far won't need changing as we see more source bytes.
    type mapFunc func(*context) bool
    
    // A spanFunc takes a context set to the current rune and returns whether this
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jan 24 13:01:26 UTC 2024
    - 22.7K bytes
    - Viewed (0)
  10. src/strconv/quote.go

    			}
    			continue // All other multibyte runes are correctly encoded and assumed printable.
    		}
    		if r == utf8.RuneError {
    			return false
    		}
    		if (r < ' ' && r != '\t') || r == '`' || r == '\u007F' {
    			return false
    		}
    	}
    	return true
    }
    
    func unhex(b byte) (v rune, ok bool) {
    	c := rune(b)
    	switch {
    	case '0' <= c && c <= '9':
    		return c - '0', true
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 04 14:21:28 UTC 2024
    - 16.5K bytes
    - Viewed (0)
Back to top