Home
last modified time | relevance | path

Searched refs:from_bytes (Results 1 - 25 of 39) sorted by relevance

12

/third_party/python/Lib/test/
H A Dtest_long.py1360 int.from_bytes(test, byteorder, signed=signed),
1371 int.from_bytes(test),
1476 self.assertIs(type(myint.from_bytes(b'\x00', 'big')), myint)
1477 self.assertEqual(myint.from_bytes(b'\x01', 'big'), 1)
1479 type(myint.from_bytes(b'\x00', 'big', signed=False)), myint)
1480 self.assertEqual(myint.from_bytes(b'\x01', 'big', signed=False), 1)
1481 self.assertIs(type(myint.from_bytes(b'\x00', 'little')), myint)
1482 self.assertEqual(myint.from_bytes(b'\x01', 'little'), 1)
1483 self.assertIs(type(myint.from_bytes(
1485 self.assertEqual(myint.from_bytes(
[all...]
H A Dtest_multibytecodec.py167 int.from_bytes(
178 int.from_bytes(
184 int.from_bytes(
191 pending_size_nine = int.from_bytes(
200 invalid_utf8 = int.from_bytes(
H A Dtest_bool.py323 self.assertIs(bool.from_bytes(b'\x00'*8, 'big'), False)
324 self.assertIs(bool.from_bytes(b'abcd', 'little'), True)
H A Dtest_pkgutil.py250 ('builtins.int.from_bytes', int.from_bytes),
251 ('builtins:int.from_bytes', int.from_bytes),
/third_party/python/Lib/
H A Dhashlib.py236 from_bytes = int.from_bytes
240 rkey = from_bytes(prev)
244 rkey ^= from_bytes(prev)
H A Dbase64.py182 from_bytes = int.from_bytes
185 c = from_bytes(s[i: i + 5]) # big endian
H A Drandom.py157 a = int.from_bytes(a + _sha512(a).digest())
798 return (int.from_bytes(_urandom(7)) >> 3) * RECIP_BPF
805 x = int.from_bytes(_urandom(numbytes))
H A Dplistlib.py509 return tuple(int.from_bytes(data[i: i + size], 'big')
546 result = int.from_bytes(self._fp.read(1 << tokenL),
584 result = UID(int.from_bytes(self._fp.read(1 + tokenL), 'big'))
H A Dipaddress.py1205 return int.from_bytes(map(cls._parse_octet, octets), 'big')
1307 self._ip = int.from_bytes(address) # big endian
1916 self._ip = int.from_bytes(address, 'big')
H A Duuid.py189 int = int_.from_bytes(bytes) # big endian
/third_party/rust/crates/os_str_bytes/src/windows/
H A Dmod.rs62 fn from_bytes(string: &[u8]) -> Result<Option<OsString>> { in from_bytes() functions
88 from_bytes(string).map(|os_string| {
103 from_bytes(&string).map(|os_string| {
H A Dtests.rs11 assert_eq!(Err(error), super::from_bytes(string)); in test_invalid()
/third_party/rust/crates/os_str_bytes/tests/
H A Dcommon.rs45 pub(crate) fn from_bytes(string: &[u8]) -> Result<Cow<'_, OsStr>> {
65 let os_string = from_bytes(string)?;
81 assert_eq!(Ok(Cow::Borrowed(os_string)), from_bytes(string));
H A Drandom.rs24 assert_eq!(Ok(Cow::Borrowed(&*os_string)), common::from_bytes(&string)); in test_bytes()
/third_party/rust/crates/os_str_bytes/src/wasm/
H A Dmod.rs38 fn from_bytes(string: &[u8]) -> Result<&str> { in from_bytes() functions
43 from_bytes(string).map(|x| Cow::Borrowed(OsStr::new(x)))
H A Draw.rs18 super::from_bytes(string).map(drop)
/third_party/skia/third_party/externals/angle2/src/common/
H A Dsystem_utils_winuwp.cpp39 std::wstring wideBuffer = converter.from_bytes(libraryName); in UwpLibrary()
/third_party/rust/crates/nix/src/sys/
H A Dutsname.rs63 OsStr::from_bytes(bytes) in cast_and_trim()
H A Dinotify.rs220 Some(OsStr::from_bytes(cstr.to_bytes()).to_owned()) in read_events()
/third_party/rust/crates/rustix/src/path/
H A Ddec_int.rs116 let as_os_str: &OsStr = OsStrExt::from_bytes(&self.buf[..self.len]); in as_ref()
/third_party/python/Lib/importlib/
H A D_bootstrap_external.py87 return int.from_bytes(data, 'little')
92 return int.from_bytes(data, 'little')
422 _RAW_MAGIC_NUMBER = int.from_bytes(MAGIC_NUMBER, 'little') # For import.c
/third_party/python/Lib/test/test_importlib/source/
H A Dtest_file_loader.py265 self.assertEqual(int.from_bytes(data[4:8], 'little'), 0b11)
320 self.assertEqual(int.from_bytes(data[4:8], 'little'), 0b1)
351 self.assertEqual(int.from_bytes(data[4:8], 'little'), 0b1)
/third_party/googletest/googletest/include/gtest/internal/
H A Dgtest-port.h2095 std::wstring wide_path = converter.from_bytes(path); in FOpen()
2096 std::wstring wide_mode = converter.from_bytes(mode); in FOpen()
/third_party/node/deps/googletest/include/gtest/internal/
H A Dgtest-port.h2111 std::wstring wide_path = converter.from_bytes(path); in FOpen()
2112 std::wstring wide_mode = converter.from_bytes(mode); in FOpen()
/third_party/rust/crates/nix/src/sys/socket/
H A Daddr.rs803 Self::Pathname(Path::new(OsStr::from_bytes(
807 Self::Pathname(Path::new(OsStr::from_bytes(pathname)))

Completed in 27 milliseconds

12