• Home
  • Raw
  • Download

Lines Matching full:needed

19 /// # use nom::{Err, error::ErrorKind, Needed};
27 /// assert_eq!(parser(&b""[..]), Err(Err::Incomplete(Needed::new(1))));
36 Err(Err::Incomplete(Needed::new(1))) in be_u8()
49 /// # use nom::{Err, error::ErrorKind, Needed};
57 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(1))));
66 Err(Err::Incomplete(Needed::new(bound - input.input_len()))) in be_u16()
82 /// # use nom::{Err, error::ErrorKind, Needed};
90 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(2))));
99 Err(Err::Incomplete(Needed::new(bound - input.input_len()))) in be_u24()
115 /// # use nom::{Err, error::ErrorKind, Needed};
123 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(3))));
132 Err(Err::Incomplete(Needed::new(bound - input.input_len()))) in be_u32()
148 /// # use nom::{Err, error::ErrorKind, Needed};
156 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(7))));
165 Err(Err::Incomplete(Needed::new(bound - input.input_len()))) in be_u64()
180 /// # use nom::{Err, error::ErrorKind, Needed};
188 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(15))));
197 Err(Err::Incomplete(Needed::new(bound - input.input_len()))) in be_u128()
212 /// # use nom::{Err, error::ErrorKind, Needed};
218 /// assert_eq!(parser(&b""[..]), Err(Err::Incomplete(Needed::new(1))));
232 /// # use nom::{Err, error::ErrorKind, Needed};
238 /// assert_eq!(parser(&b""[..]), Err(Err::Incomplete(Needed::new(2))));
252 /// # use nom::{Err, error::ErrorKind, Needed};
258 /// assert_eq!(parser(&b""[..]), Err(Err::Incomplete(Needed::new(3))));
281 /// # use nom::{Err, error::ErrorKind, Needed};
287 /// assert_eq!(parser(&b""[..]), Err(Err::Incomplete(Needed::new(4))));
302 /// # use nom::{Err, error::ErrorKind, Needed};
308 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(7))));
322 /// # use nom::{Err, error::ErrorKind, Needed};
328 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(15))));
342 /// # use nom::{Err, error::ErrorKind, Needed};
348 /// assert_eq!(parser(&b""[..]), Err(Err::Incomplete(Needed::new(1))));
357 Err(Err::Incomplete(Needed::new(1))) in le_u8()
370 /// # use nom::{Err, error::ErrorKind, Needed};
378 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(1))));
387 Err(Err::Incomplete(Needed::new(bound - input.input_len()))) in le_u16()
403 /// # use nom::{Err, error::ErrorKind, Needed};
411 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(2))));
420 Err(Err::Incomplete(Needed::new(bound - input.input_len()))) in le_u24()
436 /// # use nom::{Err, error::ErrorKind, Needed};
444 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(3))));
453 Err(Err::Incomplete(Needed::new(bound - input.input_len()))) in le_u32()
469 /// # use nom::{Err, error::ErrorKind, Needed};
477 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(7))));
486 Err(Err::Incomplete(Needed::new(bound - input.input_len()))) in le_u64()
502 /// # use nom::{Err, error::ErrorKind, Needed};
510 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(15))));
519 Err(Err::Incomplete(Needed::new(bound - input.input_len()))) in le_u128()
534 /// # use nom::{Err, error::ErrorKind, Needed};
540 /// assert_eq!(parser(&b""[..]), Err(Err::Incomplete(Needed::new(1))));
555 /// # use nom::{Err, error::ErrorKind, Needed};
563 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(1))));
578 /// # use nom::{Err, error::ErrorKind, Needed};
586 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(2))));
610 /// # use nom::{Err, error::ErrorKind, Needed};
618 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(3))));
633 /// # use nom::{Err, error::ErrorKind, Needed};
641 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(7))));
656 /// # use nom::{Err, error::ErrorKind, Needed};
664 /// assert_eq!(parser(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(15))));
679 /// # use nom::{Err, error::ErrorKind, Needed};
680 /// # use nom::Needed::Size;
688 /// assert_eq!(parser(&b""[..]), Err(Err::Incomplete(Needed::new(1))));
697 Err(Err::Incomplete(Needed::new(1))) in u8()
712 /// # use nom::{Err, error::ErrorKind, Needed};
713 /// # use nom::Needed::Size;
721 /// assert_eq!(be_u16(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(1))));
728 /// assert_eq!(le_u16(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(1))));
751 /// # use nom::{Err, error::ErrorKind, Needed};
752 /// # use nom::Needed::Size;
760 /// assert_eq!(be_u24(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(2))));
767 /// assert_eq!(le_u24(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(2))));
790 /// # use nom::{Err, error::ErrorKind, Needed};
791 /// # use nom::Needed::Size;
799 /// assert_eq!(be_u32(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(3))));
806 /// assert_eq!(le_u32(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(3))));
829 /// # use nom::{Err, error::ErrorKind, Needed};
830 /// # use nom::Needed::Size;
838 /// assert_eq!(be_u64(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(7))));
845 /// assert_eq!(le_u64(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(7))));
868 /// # use nom::{Err, error::ErrorKind, Needed};
869 /// # use nom::Needed::Size;
877 /// assert_eq!(be_u128(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(15))));
884 /// assert_eq!(le_u128(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(15))));
906 /// # use nom::{Err, error::ErrorKind, Needed};
907 /// # use nom::Needed::Size;
915 /// assert_eq!(parser(&b""[..]), Err(Err::Incomplete(Needed::new(1))));
931 /// # use nom::{Err, error::ErrorKind, Needed};
932 /// # use nom::Needed::Size;
940 /// assert_eq!(be_i16(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(1))));
947 /// assert_eq!(le_i16(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(1))));
970 /// # use nom::{Err, error::ErrorKind, Needed};
971 /// # use nom::Needed::Size;
979 /// assert_eq!(be_i24(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(2))));
986 /// assert_eq!(le_i24(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(2))));
1009 /// # use nom::{Err, error::ErrorKind, Needed};
1010 /// # use nom::Needed::Size;
1018 /// assert_eq!(be_i32(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(3))));
1025 /// assert_eq!(le_i32(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(3))));
1048 /// # use nom::{Err, error::ErrorKind, Needed};
1049 /// # use nom::Needed::Size;
1057 /// assert_eq!(be_i64(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(7))));
1064 /// assert_eq!(le_i64(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(7))));
1087 /// # use nom::{Err, error::ErrorKind, Needed};
1088 /// # use nom::Needed::Size;
1096 /// assert_eq!(be_i128(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(15))));
1103 /// assert_eq!(le_i128(&b"\x01"[..]), Err(Err::Incomplete(Needed::new(15))));
1124 /// # use nom::{Err, error::ErrorKind, Needed};
1132 /// assert_eq!(parser(&[0x01][..]), Err(Err::Incomplete(Needed::new(3))));
1149 /// # use nom::{Err, error::ErrorKind, Needed};
1157 /// assert_eq!(parser(&[0x01][..]), Err(Err::Incomplete(Needed::new(7))));
1174 /// # use nom::{Err, error::ErrorKind, Needed};
1182 /// assert_eq!(parser(&[0x01][..]), Err(Err::Incomplete(Needed::new(3))));
1199 /// # use nom::{Err, error::ErrorKind, Needed};
1207 /// assert_eq!(parser(&[0x01][..]), Err(Err::Incomplete(Needed::new(7))));
1226 /// # use nom::{Err, error::ErrorKind, Needed};
1227 /// # use nom::Needed::Size;
1235 /// assert_eq!(be_f32(&b"abc"[..]), Err(Err::Incomplete(Needed::new(1))));
1242 /// assert_eq!(le_f32(&b"abc"[..]), Err(Err::Incomplete(Needed::new(1))));
1265 /// # use nom::{Err, error::ErrorKind, Needed};
1266 /// # use nom::Needed::Size;
1274 /// assert_eq!(be_f64(&b"abc"[..]), Err(Err::Incomplete(Needed::new(5))));
1281 /// assert_eq!(le_f64(&b"abc"[..]), Err(Err::Incomplete(Needed::new(5))));
1302 /// # use nom::{Err, error::ErrorKind, Needed};
1310 /// assert_eq!(parser(b"abc"), Err(Err::Incomplete(Needed::new(1))));
1342 /// # use nom::{Err, error::ErrorKind, Needed};
1396 crate::Err::Incomplete(needed) => crate::Err::Incomplete(needed), in recognize_float_or_exceptions()
1478 None => return Err(Err::Incomplete(Needed::new(1))), in recognize_float_parts()
1517 /// # use nom::{Err, error::ErrorKind, Needed};
1518 /// # use nom::Needed::Size;
1571 /// # use nom::{Err, error::ErrorKind, Needed};
1572 /// # use nom::Needed::Size;
1624 use crate::internal::{Err, Needed};
1640 assert_parse!(be_i8(&[][..]), Err(Err::Incomplete(Needed::new(1)))); in i8_tests()
1649 assert_parse!(be_i16(&[][..]), Err(Err::Incomplete(Needed::new(2)))); in i16_tests()
1650 assert_parse!(be_i16(&[0x00][..]), Err(Err::Incomplete(Needed::new(1)))); in i16_tests()
1661 assert_parse!(be_u24(&[][..]), Err(Err::Incomplete(Needed::new(3)))); in u24_tests()
1662 assert_parse!(be_u24(&[0x00][..]), Err(Err::Incomplete(Needed::new(2)))); in u24_tests()
1665 Err(Err::Incomplete(Needed::new(1))) in u24_tests()
1677 assert_parse!(be_i24(&[][..]), Err(Err::Incomplete(Needed::new(3)))); in i24_tests()
1678 assert_parse!(be_i24(&[0x00][..]), Err(Err::Incomplete(Needed::new(2)))); in i24_tests()
1681 Err(Err::Incomplete(Needed::new(1))) in i24_tests()
1697 assert_parse!(be_i32(&[][..]), Err(Err::Incomplete(Needed::new(4)))); in i32_tests()
1698 assert_parse!(be_i32(&[0x00][..]), Err(Err::Incomplete(Needed::new(3)))); in i32_tests()
1701 Err(Err::Incomplete(Needed::new(2))) in i32_tests()
1705 Err(Err::Incomplete(Needed::new(1))) in i32_tests()
1727 assert_parse!(be_i64(&[][..]), Err(Err::Incomplete(Needed::new(8)))); in i64_tests()
1728 assert_parse!(be_i64(&[0x00][..]), Err(Err::Incomplete(Needed::new(7)))); in i64_tests()
1731 Err(Err::Incomplete(Needed::new(6))) in i64_tests()
1735 Err(Err::Incomplete(Needed::new(5))) in i64_tests()
1739 Err(Err::Incomplete(Needed::new(4))) in i64_tests()
1743 Err(Err::Incomplete(Needed::new(3))) in i64_tests()
1747 Err(Err::Incomplete(Needed::new(2))) in i64_tests()
1751 Err(Err::Incomplete(Needed::new(1))) in i64_tests()
1799 assert_parse!(be_i128(&[][..]), Err(Err::Incomplete(Needed::new(16)))); in i128_tests()
1800 assert_parse!(be_i128(&[0x00][..]), Err(Err::Incomplete(Needed::new(15)))); in i128_tests()
1803 Err(Err::Incomplete(Needed::new(14))) in i128_tests()
1807 Err(Err::Incomplete(Needed::new(13))) in i128_tests()
1811 Err(Err::Incomplete(Needed::new(12))) in i128_tests()
1815 Err(Err::Incomplete(Needed::new(11))) in i128_tests()
1819 Err(Err::Incomplete(Needed::new(10))) in i128_tests()
1823 Err(Err::Incomplete(Needed::new(9))) in i128_tests()
1827 Err(Err::Incomplete(Needed::new(8))) in i128_tests()
1831 Err(Err::Incomplete(Needed::new(7))) in i128_tests()
1835 Err(Err::Incomplete(Needed::new(6))) in i128_tests()
1839 Err(Err::Incomplete(Needed::new(5))) in i128_tests()
1843 Err(Err::Incomplete(Needed::new(4))) in i128_tests()
1847 Err(Err::Incomplete(Needed::new(3))) in i128_tests()
1853 Err(Err::Incomplete(Needed::new(2))) in i128_tests()
1860 Err(Err::Incomplete(Needed::new(1))) in i128_tests()
2039 assert_parse!(hex_u32(&b"12af"[..]), Err(Err::Incomplete(Needed::new(1)))); in hex_u32_tests()
2084 Err(Err::Incomplete(Needed::new(1))) in float_test()