Skip to content

Commit 3718db4

Browse files
author
Alberto Colombo
committed
fix: remove mutable borrow reservation warning
rust-lang/rust#59159
1 parent a788301 commit 3718db4

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

gui/src/main.rs

+4-1
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,10 @@ impl epi::App for Wordler {
8787
let last_word = self.attempts.last().unwrap();
8888
self.game.add_filters(last_word.letters.clone());
8989
match self.game.suggest_word() {
90-
Some(word) => self.attempts.push(last_word.next(word)),
90+
Some(word) => {
91+
let next_word = last_word.next(word);
92+
self.attempts.push(next_word);
93+
},
9194
_ => (),
9295
}
9396
}

0 commit comments

Comments
 (0)