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

Make socket options generic #134

rotty opened this Issue Dec 10, 2016 · 0 comments


None yet
1 participant
Copy link

rotty commented Dec 10, 2016

As hinted in the discussion of #103, it would be possible to improve the socket option API, such that it becomes possible to write code that is generic over the socket options. For example functions like these should be implementable:

fn show_option<O>(sock: &Socket, option: O) -> String
    where O: sockopt::Readable, O::Item: Debug;
fn set_option<O>(sock: &Socket, option: O, s: &str)
    where O: sockopt:Writable, O::Item: FromStr;

@rotty rotty added this to the 0.9.0 milestone Dec 10, 2016

@rotty rotty modified the milestones: 0.9.0, 0.10.0 Jan 5, 2019

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