|
Boost : |
Subject: [boost] Date_Time : Error in time_duration.hpp
From: GAURAV GUPTA (ya1gaurav_at_[hidden])
Date: 2012-11-28 06:13:18
Hello,
I have encountered some errors in Boost, while running some static analyzer
tool.
It is reported in boost/date_time/time_duration.hpp
The error is:
*boost::date_time::time_duration has user-written copy constructor but no
corresponding user-written assignment operator.*
*Is it valid to apply the following patch.*
diff -Naur a/boost/date_time/time_duration.hpp
b/boost/date_time/time_duration.hpp
--- a/boost/date_time/time_duration.hpp 2012-10-11 00:35:03.000000000 +0530
+++ b/boost/date_time/time_duration.hpp 2012-11-26 18:29:16.000000000 +0530
@@ -251,6 +251,9 @@
return ticks_;
}
+ private:
+ time_duration &operator=(const time_duration<T, rep_type>& other);
+
protected:
explicit time_duration(impl_type in) : ticks_(in) {}
impl_type ticks_; *
*
-- Regards, Gaurav
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk