1
0
Fork 0
mirror of https://github.com/ntex-rs/ntex.git synced 2025-04-05 22:07:38 +03:00

Switch to 2021 edition ()

This commit is contained in:
Nikolay Kim 2023-02-03 00:30:07 +06:00 committed by GitHub
parent 0c61a78d60
commit 29e04cf478
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
53 changed files with 54 additions and 81 deletions

View file

@ -9,7 +9,7 @@ repository = "https://github.com/ntex-rs"
readme = "README.md"
keywords = ["buffers", "zero-copy", "io"]
categories = ["network-programming", "data-structures"]
edition = "2018"
edition = "2021"
[features]
default = []

View file

@ -1,5 +1,4 @@
use std::borrow::{Borrow, BorrowMut};
use std::iter::{FromIterator, Iterator};
use std::ops::{Deref, DerefMut, RangeBounds};
use std::sync::atomic::Ordering::{Acquire, Relaxed, Release};
use std::sync::atomic::{self, AtomicUsize};
@ -4049,7 +4048,7 @@ fn abort() {
#[cfg(test)]
mod tests {
use std::{collections::HashMap, convert::TryFrom};
use std::collections::HashMap;
use super::*;

View file

@ -1,5 +1,5 @@
//! A UTF-8 encoded read-only string using Bytes as storage.
use std::{borrow, convert::TryFrom, fmt, hash, ops, slice, str};
use std::{borrow, fmt, hash, ops, slice, str};
use crate::{Bytes, BytesMut, BytesVec};

View file

@ -96,7 +96,6 @@ fn fmt() {
#[test]
fn fmt_write() {
use std::fmt::Write;
use std::iter::FromIterator;
let s = String::from_iter((0..10).map(|_| "abcdefg"));
let mut a = BytesMut::with_capacity(64);