[librsvg: 10/14] Remove unnecessary mutable references, per clippy
- From: Federico Mena Quintero <federico src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [librsvg: 10/14] Remove unnecessary mutable references, per clippy
- Date: Tue, 23 Mar 2021 19:57:56 +0000 (UTC)
commit 898e6b738fbff81e1ba46a34fe64fde21aa06105
Author: Federico Mena Quintero <federico gnome org>
Date: Tue Mar 23 12:54:05 2021 -0600
Remove unnecessary mutable references, per clippy
src/c_api/handle.rs | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/src/c_api/handle.rs b/src/c_api/handle.rs
index e83941d8..070d0a96 100644
--- a/src/c_api/handle.rs
+++ b/src/c_api/handle.rs
@@ -992,12 +992,12 @@ impl CHandle {
cr: *mut cairo_sys::cairo_t,
viewport: &cairo::Rectangle,
) -> Result<(), RenderingError> {
- let mut cr = check_cairo_context(cr)?;
+ let cr = check_cairo_context(cr)?;
let handle = self.get_handle_ref()?;
let renderer = self.make_renderer(&handle);
- Ok(renderer.render_document(&mut cr, viewport)?)
+ Ok(renderer.render_document(&cr, viewport)?)
}
fn get_geometry_for_layer(
@@ -1019,13 +1019,13 @@ impl CHandle {
id: Option<&str>,
viewport: &cairo::Rectangle,
) -> Result<(), RenderingError> {
- let mut cr = check_cairo_context(cr)?;
+ let cr = check_cairo_context(cr)?;
let handle = self.get_handle_ref()?;
let renderer = self.make_renderer(&handle);
- Ok(renderer.render_layer(&mut cr, id, viewport)?)
+ Ok(renderer.render_layer(&cr, id, viewport)?)
}
fn get_geometry_for_element(
@@ -1047,13 +1047,13 @@ impl CHandle {
id: Option<&str>,
element_viewport: &cairo::Rectangle,
) -> Result<(), RenderingError> {
- let mut cr = check_cairo_context(cr)?;
+ let cr = check_cairo_context(cr)?;
let handle = self.get_handle_ref()?;
let renderer = self.make_renderer(&handle);
- Ok(renderer.render_element(&mut cr, id, element_viewport)?)
+ Ok(renderer.render_element(&cr, id, element_viewport)?)
}
fn get_intrinsic_dimensions(&self) -> Result<IntrinsicDimensions, RenderingError> {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]