Created
January 24, 2018 00:58
-
-
Save tecywiz121/edccdc276633391bc5281e10754777ed to your computer and use it in GitHub Desktop.
How do I
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#[derive(Deserialize)] | |
struct Demo { | |
d1: Demo<i32>, | |
d2: Demo<String>, | |
d3: Demo<String>, | |
} | |
enum DemoEnum<T> { | |
A, | |
B, | |
C(T), | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
d1 = "A" # DemoEnum::A | |
d2 = "B" # DemoEnum::B | |
d3 = "hello" # DemoEnum::C("hello") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment