aboutsummaryrefslogtreecommitdiff
path: root/azalea-brigadier/src
diff options
context:
space:
mode:
Diffstat (limited to 'azalea-brigadier/src')
-rw-r--r--azalea-brigadier/src/command_dispatcher.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/azalea-brigadier/src/command_dispatcher.rs b/azalea-brigadier/src/command_dispatcher.rs
index eaf4a5e0..a5afe0da 100644
--- a/azalea-brigadier/src/command_dispatcher.rs
+++ b/azalea-brigadier/src/command_dispatcher.rs
@@ -1,7 +1,7 @@
use std::{
cmp::Ordering,
collections::{HashMap, HashSet},
- mem,
+ mem, ptr,
rc::Rc,
sync::Arc,
};
@@ -349,7 +349,7 @@ impl<S> CommandDispatcher<S> {
}
match &node.redirect {
Some(redirect) => {
- let redirect = if redirect.data_ptr() == self.root.data_ptr() {
+ let redirect = if ptr::eq(redirect.data_ptr(), self.root.data_ptr()) {
"...".to_string()
} else {
format!("-> {}", redirect.read().usage_text())
@@ -427,7 +427,7 @@ impl<S> CommandDispatcher<S> {
}
if let Some(redirect) = &node.redirect {
- let redirect = if redirect.data_ptr() == self.root.data_ptr() {
+ let redirect = if ptr::eq(redirect.data_ptr(), self.root.data_ptr()) {
"...".to_string()
} else {
format!("-> {}", redirect.read().usage_text())