merge stable version #2

Merged
doryan merged 97 commits from experimental into main 2024-08-28 18:54:00 +03:00
Showing only changes of commit 2ce75224fa - Show all commits

View File

@ -6,8 +6,9 @@ use std::ops::Deref;
const ASCII_ZERO_CHAR_POSITION: u8 = 48;
pub fn processing_input(input: &String) -> String {
pub fn processing_input(input: impl Into<String>) -> String {
input
.into()
.split_ascii_whitespace()
.filter(|&x| !x.is_empty())
.fold(String::new(), |c: String, n: &str| c + n)
@ -20,8 +21,9 @@ pub fn from_vec_bits_to_string(raw_data: &[u8]) -> String {
.collect()
}
pub fn from_string_to_vec_bits(raw_data: String) -> Vec<u8> {
pub fn from_string_to_vec_bits(raw_data: impl Into<String>) -> Vec<u8> {
raw_data
.into()
.as_bits::<Lsb0>()
.iter()
.step_by(8)