Clippy fixes and documentation
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
@@ -543,7 +543,7 @@ impl Pokemon {
|
||||
|
||||
/// Change the form of the Pokemon.
|
||||
pub fn change_form(&self, form: &Arc<dyn Form>) -> Result<()> {
|
||||
if Arc::ptr_eq(&self.form(), form) {
|
||||
if self.form().eq(form.deref()) {
|
||||
return Ok(());
|
||||
}
|
||||
*self.data.form.write() = form.clone();
|
||||
@@ -816,6 +816,7 @@ impl Pokemon {
|
||||
}
|
||||
}
|
||||
|
||||
/// Gets the inner pointer to the reference counted data.
|
||||
pub fn as_ptr(&self) -> *const c_void {
|
||||
Arc::as_ptr(&self.data) as *const c_void
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user