- Sort Score
- Result 10 results
- Languages All
Results 1 - 5 of 5 for unhex (0.04 sec)
-
src/mime/mediatype.go
} i += 3 } if percents == 0 { return s, nil } t := make([]byte, len(s)-2*percents) j := 0 for i := 0; i < len(s); { switch s[i] { case '%': t[j] = unhex(s[i+1])<<4 | unhex(s[i+2]) j++ i += 3 default: t[j] = s[i] j++ i++ } } return string(t), nil } func ishex(c byte) bool { switch { case '0' <= c && c <= '9':
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:00:11 UTC 2024 - 9.8K bytes - Viewed (0) -
src/net/url/url.go
// That is, you can use escaping in the zone identifier but not // to introduce bytes you couldn't just write directly. // But Windows puts spaces here! Yay. v := unhex(s[i+1])<<4 | unhex(s[i+2]) if s[i:i+3] != "%25" && v != ' ' && shouldEscape(v, encodeHost) { return "", EscapeError(s[i : i+3]) } } i += 3 case '+': hasPlus = mode == encodeQueryComponent
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:16:53 UTC 2024 - 36.1K bytes - Viewed (0) -
src/strconv/quote.go
} 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 case 'a' <= c && c <= 'f': return c - 'a' + 10, true case 'A' <= c && c <= 'F':
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Apr 04 14:21:28 UTC 2024 - 16.5K bytes - Viewed (0) -
src/regexp/syntax/parse.go
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/crypto/rsa/pss_test.go
opts := &PSSOptions{ SaltLength: PSSSaltLengthEqualsHash, } for marker := range values { switch marker { case newKeyMarker: key = new(PublicKey) nHex, ok := <-values if !ok { continue } key.N = bigFromHex(nHex) key.E = intFromHex(<-values) // We don't care for d, p, q, dP, dQ or qInv. for i := 0; i < 6; i++ { <-values } case newSignatureMarker:
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 18:42:28 UTC 2024 - 8.8K bytes - Viewed (0)