Remove #[allow(unused_variables)]#493
Merged
coriolinus merged 6 commits intoexercism:masterfrom Apr 8, 2018
Merged
Conversation
petertseng
approved these changes
Apr 8, 2018
Member
petertseng
left a comment
There was a problem hiding this comment.
Yup. Note one inconsistent capitalisation. I Approve despite this because the fix will be trivial and because I expect to be unavailable for hours.
| pub fn remove_callback(&mut self, cell: CellID, callback: CallbackID) -> Result<(), RemoveCallbackError> { | ||
| unimplemented!() | ||
| unimplemented!( | ||
| "Remove the callback identified by the CallbackId {:?} from the cell {:?}", |
Member
There was a problem hiding this comment.
CallbackId's capitalisation is inconsistent with the fact that CallbackID is used a few lines above
9f847e7 to
514870c
Compare
Note that in this case, we couldn't follow the standard procedure of adding the variables to the unimplemented block, because the generic types F and T aren't bounded by Debug. Worse, the closures expected for F possibly _can't_ be bounded by Debug. We use named underscore variables as a fallback.
514870c to
15473b9
Compare
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #481.
Note that in the case of the react exercise, it wasn't possible to follow the standard procedure of adding a use of the variables in the unimplemented block. This is because react uses the generic types
FandT, which are not bounded by theDebugtrait. In that case, I fell back to the underscore-prefix pattern; students who reach a level 10 exercise should not be confused by it.