summaryrefslogtreecommitdiff
path: root/exercises/14_generics
diff options
context:
space:
mode:
authormo8it <mo8it@proton.me>2024-06-27 02:25:11 +0200
committermo8it <mo8it@proton.me>2024-06-27 02:25:11 +0200
commitde3f846a53055bbca5ec9dd6d536a31c82d39648 (patch)
treec5ca723d1833700881b27dee0b397ccbb59167ee /exercises/14_generics
parent46121b71cf2f4da296e80fad025eaee03c67dcd5 (diff)
generics2 solution
Diffstat (limited to 'exercises/14_generics')
-rw-r--r--exercises/14_generics/generics2.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/exercises/14_generics/generics2.rs b/exercises/14_generics/generics2.rs
index 6cdcdaf..8908725 100644
--- a/exercises/14_generics/generics2.rs
+++ b/exercises/14_generics/generics2.rs
@@ -1,10 +1,10 @@
// This powerful wrapper provides the ability to store a positive integer value.
-// Rewrite it using generics so that it supports wrapping ANY type.
-
+// TODO: Rewrite it using a generic so that it supports wrapping ANY type.
struct Wrapper {
value: u32,
}
+// TODO: Adapt the struct's implementation to be generic over the wrapped value.
impl Wrapper {
fn new(value: u32) -> Self {
Wrapper { value }