cxx/test/utilities/time/time.clock/time.clock.system/from_time_t.pass.cpp

1 line
572 B
C++
Raw Normal View History

//===----------------------------------------------------------------------===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===----------------------------------------------------------------------===// // <chrono> // system_clock // static time_point from_time_t(time_t t); #include <chrono> #include <ctime> int main() { typedef std::chrono::system_clock C; C::time_point t1 = C::from_time_t(C::to_time_t(C::now())); }