Skip to content

Commit

Permalink
feat: Implement IntoResponse for alloc::string::String
Browse files Browse the repository at this point in the history
So no_std+alloc can use the normal strings.
  • Loading branch information
lu-zero committed Nov 22, 2024
1 parent 49334e3 commit ea419e2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/response.rs
Original file line number Diff line number Diff line change
Expand Up @@ -625,8 +625,8 @@ impl<const N: usize> IntoResponse for heapless::String<N> {
}
}

#[cfg(feature = "std")]
impl IntoResponse for std::string::String {
#[cfg(feature = "alloc")]
impl IntoResponse for alloc::string::String {
async fn write_to<R: Read, W: ResponseWriter<Error = R::Error>>(
self,
connection: Connection<'_, R>,
Expand Down

0 comments on commit ea419e2

Please sign in to comment.