mirror of
https://github.com/fafhrd91/actix-web
synced 2025-01-18 22:01:50 +01:00
remove crate level clippy lint
This commit is contained in:
parent
17f636a183
commit
64c2e5e1cd
@ -36,6 +36,7 @@ where
|
||||
<S::Service as Service<Request>>::Future: 'static,
|
||||
{
|
||||
/// Create instance of `ServiceConfigBuilder`
|
||||
#[allow(clippy::new_without_default)]
|
||||
pub fn new() -> Self {
|
||||
HttpServiceBuilder {
|
||||
keep_alive: KeepAlive::Timeout(5),
|
||||
|
@ -19,7 +19,6 @@
|
||||
#![allow(
|
||||
clippy::type_complexity,
|
||||
clippy::too_many_arguments,
|
||||
clippy::new_without_default,
|
||||
clippy::borrow_interior_mutable_const
|
||||
)]
|
||||
#![doc(html_logo_url = "https://actix.rs/img/logo.png")]
|
||||
@ -28,6 +27,9 @@
|
||||
#[macro_use]
|
||||
extern crate log;
|
||||
|
||||
pub use ::http::{uri, uri::Uri};
|
||||
pub use ::http::{Method, StatusCode, Version};
|
||||
|
||||
pub mod body;
|
||||
mod builder;
|
||||
mod config;
|
||||
@ -61,9 +63,6 @@ pub use self::requests::{Request, RequestHead, RequestHeadType};
|
||||
pub use self::responses::{Response, ResponseBuilder, ResponseHead};
|
||||
pub use self::service::HttpService;
|
||||
|
||||
pub use ::http::{uri, uri::Uri};
|
||||
pub use ::http::{Method, StatusCode, Version};
|
||||
|
||||
/// A major HTTP protocol version.
|
||||
#[derive(Copy, Clone, Debug, PartialEq, Eq, Hash)]
|
||||
#[non_exhaustive]
|
||||
|
@ -43,6 +43,7 @@ pub struct Message<T: Head> {
|
||||
|
||||
impl<T: Head> Message<T> {
|
||||
/// Get new message from the pool of objects
|
||||
#[allow(clippy::new_without_default)]
|
||||
pub fn new() -> Self {
|
||||
T::with_pool(MessagePool::get_message)
|
||||
}
|
||||
|
@ -1,5 +1,7 @@
|
||||
use std::pin::Pin;
|
||||
use std::task::{Context, Poll};
|
||||
use std::{
|
||||
pin::Pin,
|
||||
task::{Context, Poll},
|
||||
};
|
||||
|
||||
use bytes::Bytes;
|
||||
use futures_core::Stream;
|
||||
|
@ -59,6 +59,7 @@ impl From<Message<RequestHead>> for Request<PayloadStream> {
|
||||
|
||||
impl Request<PayloadStream> {
|
||||
/// Create new Request instance
|
||||
#[allow(clippy::new_without_default)]
|
||||
pub fn new() -> Request<PayloadStream> {
|
||||
Request {
|
||||
head: Message::new(),
|
||||
|
@ -10,10 +10,9 @@ use bytestring::ByteString;
|
||||
|
||||
use crate::{
|
||||
body::{BoxBody, MessageBody},
|
||||
extensions::Extensions,
|
||||
header::{self, HeaderMap, TryIntoHeaderValue},
|
||||
responses::{BoxedResponseHead, ResponseBuilder, ResponseHead},
|
||||
Error, StatusCode,
|
||||
responses::BoxedResponseHead,
|
||||
Error, Extensions, ResponseBuilder, ResponseHead, StatusCode,
|
||||
};
|
||||
|
||||
/// An HTTP response.
|
||||
|
Loading…
x
Reference in New Issue
Block a user