Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle borrowed data #23

Open
MathiasKoch opened this issue Mar 13, 2020 · 0 comments
Open

Handle borrowed data #23

MathiasKoch opened this issue Mar 13, 2020 · 0 comments
Labels
serde_at Issues related to the serde_at crate of the workspace wish Long-term wishes for this workspace

Comments

@MathiasKoch
Copy link
Member

When deserializing responses in serde, it should be possible to have responses with borrowed data, eg:

pub struct SocketData<'a> {
    pub socket: u8,
    pub data: &'a str,
}

ref: https://serde.rs/lifetimes.html

@MathiasKoch MathiasKoch added the serde_at Issues related to the serde_at crate of the workspace label Mar 13, 2020
@MathiasKoch MathiasKoch added the wish Long-term wishes for this workspace label Feb 11, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
serde_at Issues related to the serde_at crate of the workspace wish Long-term wishes for this workspace
Projects
None yet
Development

No branches or pull requests

1 participant