On Mon, May 05, 2025 at 11:04:30AM +0200, Paolo Bonzini wrote:
> Date: Mon,  5 May 2025 11:04:30 +0200
> From: Paolo Bonzini <pbonz...@redhat.com>
> Subject: [PATCH 05/11] rust: qemu_api_macros: make pattern matching more
>  readable and efficient
> X-Mailer: git-send-email 2.49.0
> 
> "let ... else" is useful when visiting syntax trees; it avoids multiple
> levels of indentation and places the error close to the pattern.
> 
> While at it, use "ref" to avoid moving the syntax tree objects.
> 
> Signed-off-by: Paolo Bonzini <pbonz...@redhat.com>
> ---
>  rust/qemu-api-macros/src/lib.rs | 84 +++++++++++++++------------------
>  1 file changed, 37 insertions(+), 47 deletions(-)

Good improvement!

Reviewed-by: Zhao Liu <zhao1....@intel.com>


Reply via email to