signature of equality operators
Norman Feske
norman.feske at ...1...
Mon May 18 11:45:17 CEST 2015
Hello Pirmin,
> In base/trace/types.h the signature of the operator==() for Subject_id
> is defined as follows:
> bool operator == (Subject_id const &other) { return id == other.id; }
>
> Shouldnt it be?
> bool operator == (Subject_id const &other) const { return id == other.id; }
>
> Most recomendations on operator overloading, I have read, recommend this.
thank you for reporting this issue. The const qualifier is indeed
missing. I just added it in the following commit (to the staging branch):
https://github.com/genodelabs/genode/commit/dc838779c9b7d94e78d5a76e376b4dae098358b2
Cheers
Norman
--
Dr.-Ing. Norman Feske
Genode Labs
http://www.genode-labs.com · http://genode.org
Genode Labs GmbH · Amtsgericht Dresden · HRB 28424 · Sitz Dresden
Geschäftsführer: Dr.-Ing. Norman Feske, Christian Helmuth
More information about the users
mailing list