Lines Matching refs:IMPOSSIBLE
10 use super::{ParseResult, IMPOSSIBLE, NOT_ENOUGH, OUT_OF_RANGE};
121 Err(IMPOSSIBLE) in set_if_consistent()
344 Err(IMPOSSIBLE) in to_naive_date()
516 Err(IMPOSSIBLE) in to_naive_date()
585 return Err(IMPOSSIBLE); in to_naive_datetime_with_offset()
598 (Err(PE(Impossible)), _) | (_, Err(PE(Impossible))) => return Err(IMPOSSIBLE), in to_naive_datetime_with_offset()
620 _ => return Err(IMPOSSIBLE), in to_naive_datetime_with_offset()
659 LocalResult::None => Err(IMPOSSIBLE), in to_datetime()
699 LocalResult::None => Err(IMPOSSIBLE), in to_datetime_with_timezone()
704 Err(IMPOSSIBLE) in to_datetime_with_timezone()
710 (false, false) => Err(IMPOSSIBLE), in to_datetime_with_timezone()
722 use super::super::{IMPOSSIBLE, NOT_ENOUGH, OUT_OF_RANGE};
734 assert_eq!(p.set_year(1986), Err(IMPOSSIBLE)); in test_parsed_set_fields()
735 assert_eq!(p.set_year(1988), Err(IMPOSSIBLE)); in test_parsed_set_fields()
738 assert_eq!(p.set_year_div_100(21), Err(IMPOSSIBLE)); in test_parsed_set_fields()
739 assert_eq!(p.set_year_div_100(19), Err(IMPOSSIBLE)); in test_parsed_set_fields()
741 assert_eq!(p.set_year_mod_100(38), Err(IMPOSSIBLE)); in test_parsed_set_fields()
742 assert_eq!(p.set_year_mod_100(36), Err(IMPOSSIBLE)); in test_parsed_set_fields()
753 assert_eq!(p.set_year(-2), Err(IMPOSSIBLE)); in test_parsed_set_fields()
754 assert_eq!(p.set_year(0), Err(IMPOSSIBLE)); in test_parsed_set_fields()
764 assert_eq!(p.set_month(1), Err(IMPOSSIBLE)); in test_parsed_set_fields()
765 assert_eq!(p.set_month(6), Err(IMPOSSIBLE)); in test_parsed_set_fields()
766 assert_eq!(p.set_month(8), Err(IMPOSSIBLE)); in test_parsed_set_fields()
767 assert_eq!(p.set_month(12), Err(IMPOSSIBLE)); in test_parsed_set_fields()
776 assert_eq!(p.set_hour(11), Err(IMPOSSIBLE)); in test_parsed_set_fields()
777 assert_eq!(p.set_hour(13), Err(IMPOSSIBLE)); in test_parsed_set_fields()
779 assert_eq!(p.set_ampm(false), Err(IMPOSSIBLE)); in test_parsed_set_fields()
783 assert_eq!(p.set_hour12(1), Err(IMPOSSIBLE)); in test_parsed_set_fields()
784 assert_eq!(p.set_hour12(11), Err(IMPOSSIBLE)); in test_parsed_set_fields()
789 assert_eq!(p.set_hour(7), Err(IMPOSSIBLE)); in test_parsed_set_fields()
790 assert_eq!(p.set_hour(18), Err(IMPOSSIBLE)); in test_parsed_set_fields()
796 assert_eq!(p.set_timestamp(1_234_567_889), Err(IMPOSSIBLE)); in test_parsed_set_fields()
797 assert_eq!(p.set_timestamp(1_234_567_891), Err(IMPOSSIBLE)); in test_parsed_set_fields()
868 assert_eq!(parse!(year: 1984, year_div_100: 20, month: 1, day: 1), Err(IMPOSSIBLE)); in test_parsed_to_naive_date()
870 assert_eq!(parse!(year: 1984, year_mod_100: 83, month: 1, day: 1), Err(IMPOSSIBLE)); in test_parsed_to_naive_date()
877 Err(IMPOSSIBLE) in test_parsed_to_naive_date()
929 Err(IMPOSSIBLE) in test_parsed_to_naive_date()
933 Err(IMPOSSIBLE) in test_parsed_to_naive_date()
976 Err(IMPOSSIBLE) in test_parsed_to_naive_date()
1093 Err(IMPOSSIBLE) in test_parsed_to_naive_datetime_with_offset()
1126 assert_eq!(parse!(second: 59, timestamp: 1_341_100_798), Err(IMPOSSIBLE)); in test_parsed_to_naive_datetime_with_offset()
1128 assert_eq!(parse!(second: 59, timestamp: 1_341_100_800), Err(IMPOSSIBLE)); in test_parsed_to_naive_datetime_with_offset()
1138 assert_eq!(parse!(second: 1, timestamp: 1_341_100_800), Err(IMPOSSIBLE)); in test_parsed_to_naive_datetime_with_offset()
1139 assert_eq!(parse!(second: 60, timestamp: 1_341_100_801), Err(IMPOSSIBLE)); in test_parsed_to_naive_datetime_with_offset()
1146 Err(IMPOSSIBLE) in test_parsed_to_naive_datetime_with_offset()
1156 Err(IMPOSSIBLE) in test_parsed_to_naive_datetime_with_offset()
1176 Err(IMPOSSIBLE) in test_parsed_to_naive_datetime_with_offset()
1181 Err(IMPOSSIBLE) in test_parsed_to_naive_datetime_with_offset()
1251 Err(IMPOSSIBLE) in test_parsed_to_datetime_with_timezone()
1257 Err(IMPOSSIBLE) in test_parsed_to_datetime_with_timezone()
1271 assert_eq!(parse!(Utc; timestamp: 1_420_000_000, offset: 32400), Err(IMPOSSIBLE)); in test_parsed_to_datetime_with_timezone()
1274 Err(IMPOSSIBLE) in test_parsed_to_datetime_with_timezone()