Re: [PATCH kvm-unit-tests 2/4] Introduce a C++ wrapper for the kvm APIs

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

 



On 11/24/2010 08:53 AM, Avi Kivity wrote:
struct x86_vcpu : public vcpu
{
     uint64_t eax;
     uint64_t ebx;
     uint64_t ecx;
     //...

    void get_gps(void);
    void put_gps(void);
    void get_sregs(void);
    void put_sregs(void);

    std::string repr(void);
};

I'm not of the opinion that all members need getters and setters. I think it's perfectly fine to have public variables if the reads and writes don't have side effects.


I see. Well that belongs elsewhere, this is intended as a thin wrapper that doesn't allows you to exercise the API directly. I don't want things to happen automatically here, this is for a test framework.

That's fine.

Regards,

Anthony Liguori


--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux