Fix new warnings on Nightly

This commit is contained in:
Simon Ask Ulsnes 2024-02-24 08:42:24 +01:00
parent 092bf829a7
commit abe9316a63
5 changed files with 15 additions and 9 deletions

View file

@ -1,7 +1,5 @@
use std::collections::VecDeque;
use alloc::string::String;
use crate::macros::{
is_alpha, is_ascii, is_blank, is_blankz, is_bom, is_break, is_breakz, is_printable, is_space,
};

View file

@ -167,8 +167,6 @@ pub enum MappingStyle {
#[cfg(test)]
mod tests {
use alloc::vec::Vec;
use super::*;
#[test]

View file

@ -215,3 +215,18 @@ macro_rules! IS_BLANKZ {
IS_BLANKZ_AT!($string, 0)
};
}
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn printable() {
for ch in "🎉".chars() {
assert!(is_printable(ch));
}
for ch in "\u{1f389}".chars() {
assert!(is_printable(ch));
}
}
}

View file

@ -1,6 +1,3 @@
use alloc::string::String;
use alloc::{vec, vec::Vec};
use crate::scanner::Scanner;
use crate::{
Encoding, Error, Event, EventData, MappingStyle, Mark, Result, ScalarStyle, SequenceStyle,

View file

@ -1,7 +1,5 @@
use std::collections::VecDeque;
use alloc::string::String;
use crate::macros::{is_blankz, is_break};
use crate::reader::yaml_parser_update_buffer;
use crate::{