qemu-rust
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] rust: tests: do not import bindings::*


From: Daniel P . Berrangé
Subject: Re: [PATCH] rust: tests: do not import bindings::*
Date: Fri, 14 Feb 2025 14:01:42 +0000
User-agent: Mutt/2.2.13 (2024-03-09)

On Fri, Feb 14, 2025 at 02:58:22PM +0100, Paolo Bonzini wrote:
> Similar to the devices, spell the exact set of C functions that are
> called directly.
> 
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> ---
>  rust/qemu-api/tests/tests.rs | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/rust/qemu-api/tests/tests.rs b/rust/qemu-api/tests/tests.rs
> index 92dbfb8a0c8..03569e4a44c 100644
> --- a/rust/qemu-api/tests/tests.rs
> +++ b/rust/qemu-api/tests/tests.rs
> @@ -8,13 +8,14 @@
>  };
>  
>  use qemu_api::{
> -    bindings::*,
> +    bindings::{module_call_init, module_init_type, object_new, object_unref, 
> qdev_prop_bool},
>      c_str,
>      cell::{self, BqlCell},
>      declare_properties, define_property,
>      prelude::*,

Should this be expanded too if we want to discourage wildcard imports ?

>      qdev::{DeviceClass, DeviceImpl, DeviceState, Property, 
> ResettablePhasesImpl},
>      qom::{ClassInitImpl, ObjectImpl, ParentField},
> +    sysbus::SysBusDevice,

This addition seems distinct from the bindings::* removal. Should it
have been a separate patch ?

>      vmstate::VMStateDescription,
>      zeroable::Zeroable,
>  };

With regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|




reply via email to

[Prev in Thread] Current Thread [Next in Thread]