- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 33 for maxRune (0.26 sec)
-
src/unicode/utf16/utf16_test.go
"reflect" "testing" "unicode" . "unicode/utf16" ) // Validate the constants redefined from unicode. func TestConstants(t *testing.T) { if MaxRune != unicode.MaxRune { t.Errorf("utf16.maxRune is wrong: %x should be %x", MaxRune, unicode.MaxRune) } if ReplacementChar != unicode.ReplacementChar { t.Errorf("utf16.replacementChar is wrong: %x should be %x", ReplacementChar, unicode.ReplacementChar) } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Mar 07 19:08:48 UTC 2024 - 6.5K bytes - Viewed (0) -
src/unicode/utf16/utf16.go
package utf16 // The conditions replacementChar==unicode.ReplacementChar and // maxRune==unicode.MaxRune are verified in the tests. // Defining them locally avoids this package depending on package unicode. const ( replacementChar = '\uFFFD' // Unicode replacement character maxRune = '\U0010FFFF' // Maximum valid Unicode code point. ) const (
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Mar 07 19:08:48 UTC 2024 - 3.9K bytes - Viewed (0) -
src/unicode/utf16/export_test.go
package utf16 // Extra names for constants so we can validate them during testing. const ( Surr1 = surr1 Surr3 = surr3 SurrSelf = surrSelf MaxRune = maxRune ReplacementChar = replacementChar
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Mar 07 19:08:48 UTC 2024 - 394 bytes - Viewed (0) -
src/strconv/makeisprint.go
} return y } func main() { flag.Parse() rang, except := scan(0, 0xFFFF) range16 = to16(rang) except16 = to16(except) range32, except32 = scan(0x10000, unicode.MaxRune) for i := rune(0); i <= unicode.MaxRune; i++ { if isPrint(i) != unicode.IsPrint(i) { log.Fatalf("%U: isPrint=%v, want %v\n", i, isPrint(i), unicode.IsPrint(i)) } } var buf bytes.Buffer
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Mar 11 18:56:17 UTC 2024 - 4.3K bytes - Viewed (0) -
src/unicode/letter.go
// license that can be found in the LICENSE file. // Package unicode provides data and functions to test some properties of // Unicode code points. package unicode const ( MaxRune = '\U0010FFFF' // Maximum valid Unicode code point. ReplacementChar = '\uFFFD' // Represents invalid code points. MaxASCII = '\u007F' // maximum ASCII value.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Nov 06 20:02:46 UTC 2023 - 10K bytes - Viewed (0) -
src/unicode/utf8/utf8.go
// MaxRune==unicode.MaxRune are verified in the tests. // Defining them locally avoids this package depending on package unicode. // Numbers fundamental to the encoding. const ( RuneError = '\uFFFD' // the "error" Rune or "Unicode replacement character" RuneSelf = 0x80 // characters below RuneSelf are represented as themselves in a single byte.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Mar 08 02:00:36 UTC 2024 - 16.4K bytes - Viewed (0) -
src/strings/strings_test.go
// 1. Grow. This triggers two reallocations in Map. maxRune := func(rune) rune { return unicode.MaxRune } m := Map(maxRune, a) expect := tenRunes(unicode.MaxRune) if m != expect { t.Errorf("growing: expected %q got %q", expect, m) } // 2. Shrink minRune := func(rune) rune { return 'a' } m = Map(minRune, tenRunes(unicode.MaxRune)) expect = a if m != expect {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 03 12:58:37 UTC 2024 - 53K bytes - Viewed (0) -
src/fmt/format.go
// If the character is not valid Unicode, it will print '\ufffd'. func (f *fmt) fmtC(c uint64) { // Explicitly check whether c exceeds utf8.MaxRune since the conversion // of a uint64 to a rune may lose precision that indicates an overflow. r := rune(c) if c > utf8.MaxRune { r = utf8.RuneError } buf := f.intbuf[:0] f.pad(utf8.AppendRune(buf, r)) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Mar 04 17:31:55 UTC 2024 - 13.8K bytes - Viewed (0) -
src/regexp/syntax/parse.go
case OpCharClass: re.Rune = cleanClass(&re.Rune) if len(re.Rune) == 2 && re.Rune[0] == 0 && re.Rune[1] == unicode.MaxRune { re.Rune = nil re.Op = OpAnyChar return } if len(re.Rune) == 4 && re.Rune[0] == 0 && re.Rune[1] == '\n'-1 && re.Rune[2] == '\n'+1 && re.Rune[3] == unicode.MaxRune { re.Rune = nil re.Op = OpAnyCharNotNL return } if cap(re.Rune)-len(re.Rune) > 100 {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Apr 02 13:59:01 UTC 2024 - 52.1K bytes - Viewed (0) -
src/internal/fuzz/encoding_test.go
f.Add(rune(-1)) f.Add(rune(0xd800)) f.Add(rune(0xdfff)) f.Add(rune(unicode.ReplacementChar)) f.Add(rune(unicode.MaxASCII)) f.Add(rune(unicode.MaxLatin1)) f.Add(rune(unicode.MaxRune)) f.Add(rune(unicode.MaxRune + 1)) f.Add(rune(-0x80000000)) f.Add(rune(0x7fffffff)) f.Fuzz(func(t *testing.T, r1 rune) { b := marshalCorpusFile(r1) t.Logf("marshaled rune(0x%x):\n%s", r1, b)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Mar 07 00:20:34 UTC 2024 - 8.2K bytes - Viewed (0)