mirror of
https://github.com/rust-lang/rustlings
synced 2024-11-10 14:44:25 +00:00
Derive Eq when PartialEq is derived
This commit is contained in:
parent
9c6f56b836
commit
853d0593d0
1 changed files with 2 additions and 2 deletions
|
@ -58,7 +58,7 @@ pub struct Exercise {
|
||||||
|
|
||||||
// An enum to track of the state of an Exercise.
|
// An enum to track of the state of an Exercise.
|
||||||
// An Exercise can be either Done or Pending
|
// An Exercise can be either Done or Pending
|
||||||
#[derive(PartialEq, Debug)]
|
#[derive(PartialEq, Eq, Debug)]
|
||||||
pub enum State {
|
pub enum State {
|
||||||
// The state of the exercise once it's been completed
|
// The state of the exercise once it's been completed
|
||||||
Done,
|
Done,
|
||||||
|
@ -67,7 +67,7 @@ pub enum State {
|
||||||
}
|
}
|
||||||
|
|
||||||
// The context information of a pending exercise
|
// The context information of a pending exercise
|
||||||
#[derive(PartialEq, Debug)]
|
#[derive(PartialEq, Eq, Debug)]
|
||||||
pub struct ContextLine {
|
pub struct ContextLine {
|
||||||
// The source code that is still pending completion
|
// The source code that is still pending completion
|
||||||
pub line: String,
|
pub line: String,
|
||||||
|
|
Loading…
Reference in a new issue