preserve ABI

experiment/meta_header v3.1.1
Martchus 7 years ago
parent d71e6c56d4
commit df9c0573bf
  1. 11
      chrono/datetime.cpp
  2. 9
      chrono/datetime.h

@ -5,6 +5,7 @@
#include <sstream>
#include <iomanip>
#include <stdexcept>
#include <ctime>
using namespace std;
using namespace ChronoUtilities;
@ -34,6 +35,14 @@ inline bool inRangeExclMax(num1 val, num2 min, num3 max)
return (val) >= (min) && (val) < (max);
}
/*!
* \brief Gets a DateTime object that is set to the current date and time on this computer, expressed as the local time.
*/
DateTime DateTime::now()
{
return DateTime::fromTimeStamp(time(nullptr));
}
/*!
* \class ChronoUtilities::DateTime
* \brief Represents an instant in time, typically expressed as a date and time of day.
@ -270,5 +279,3 @@ int DateTime::getDatePart(DatePart part) const
}
return 0;
}

@ -6,7 +6,6 @@
#include "../conversion/types.h"
#include <string>
#include <ctime>
#include <limits>
namespace ChronoUtilities
@ -315,14 +314,6 @@ constexpr inline DateTime DateTime::eternity()
return DateTime(std::numeric_limits<decltype(m_ticks)>::max());
}
/*!
* \brief Gets a DateTime object that is set to the current date and time on this computer, expressed as the local time.
*/
inline DateTime DateTime::now()
{
return DateTime::fromTimeStamp(time(nullptr));
}
/*!
* \brief Indicates whether two DateTime instances are equal.
*/

Loading…
Cancel
Save