Merge pull request #5 from r0e/master
[rust-101.git] / workspace / src / part11.rs
index ac19371db6d69594d87526d5e46d7267f4631de9..746aed9e96398b6b03cc8f033cdeec25764919a2 100644 (file)
@@ -23,7 +23,7 @@ impl Callbacks {
 
     // Registration simply stores the callback.
     pub fn register(&mut self, callback: Box<FnMut(i32)>) {
-        unimplemented!()
+        self.callbacks.push(callback);
     }
 
     // We can also write a generic version of `register`, such that it will be instantiated with some concrete closure type `F`