liblog: remove obsolete comment
The log_time struct satisfies all of the requirements for an implicitly created copy constructor to be present, so not defining one here does not have any real effect. We don't want to delete the copy constructor for the rationale given either; modern C++ favors passing small types by value instead of by reference as the compiler has more opportunity for optimization in that case. That's especially true here, where the size of this struct is the size of a pointer on 64 bit systems. Test: the copy constructor exists for log_time Change-Id: Id314ca7729f4b1ca02adb6c7f0ae759b22be2a5c
This commit is contained in:
parent
a5a107fb6d
commit
4e58c84854
|
@ -35,11 +35,6 @@
|
|||
|
||||
extern "C" {
|
||||
|
||||
/*
|
||||
* NB: we did NOT define a copy constructor. This will result in structure
|
||||
* no longer being compatible with pass-by-value which is desired
|
||||
* efficient behavior. Also, pass-by-reference breaks C/C++ ABI.
|
||||
*/
|
||||
struct log_time {
|
||||
public:
|
||||
uint32_t tv_sec = 0; /* good to Feb 5 2106 */
|
||||
|
|
Loading…
Reference in New Issue