Skip to content

CursedObjectConstructor#203

Draft
aliemjay wants to merge 3 commits intoHFQR:mainfrom
aliemjay:cursed
Draft

CursedObjectConstructor#203
aliemjay wants to merge 3 commits intoHFQR:mainfrom
aliemjay:cursed

Conversation

@aliemjay
Copy link
Contributor

No description provided.

@aliemjay aliemjay marked this pull request as draft April 30, 2022 12:35
@aliemjay
Copy link
Contributor Author

I'll look into web failure later

*req.uri_mut() = Uri::from_static("/abc");

let res = service.call(req).await.unwrap();
let res = Service::<Request<_>>::call(&service, req).await.unwrap();
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems that type inference have a hard time with such highly generic code. Though i wouldn't mind some turbofish api to guide inference for Req like with GenericRouter::with_custom_object.

But why it doesn't require annotations in Context tests. Needs more investigation and experimenting with other possible variations.

@aliemjay
Copy link
Contributor Author

aliemjay commented May 1, 2022

Wow. The breakage of the examples looks like a deal breaker. 😞

@fakeshadow
Copy link
Collaborator

with router that hide the lifetimes behind reference counting string type the need of Request<'_> is absent for now.

But zero copy deserialize types like Query<'_> and Json<'_> is still the highest thought after feature based on this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants