libcxx

libcxx mirror with random patches
git clone https://git.neptards.moe/neptards/libcxx.git
Log | Files | Refs

rep_signed.pass.cpp (795B)


      1 //===----------------------------------------------------------------------===//
      2 //
      3 //                     The LLVM Compiler Infrastructure
      4 //
      5 // This file is dual licensed under the MIT and the University of Illinois Open
      6 // Source Licenses. See LICENSE.TXT for details.
      7 //
      8 //===----------------------------------------------------------------------===//
      9 
     10 // UNSUPPORTED: c++98, c++03, c++11, c++14, c++17
     11 
     12 // TODO: Remove this when filesystem gets integrated into the dylib
     13 // REQUIRES: c++filesystem
     14 
     15 // <chrono>
     16 
     17 // file_clock
     18 
     19 // rep should be signed
     20 
     21 #include <chrono>
     22 #include <cassert>
     23 
     24 int main()
     25 {
     26     static_assert(std::is_signed<std::chrono::file_clock::rep>::value, "");
     27     assert(std::chrono::file_clock::duration::min() <
     28            std::chrono::file_clock::duration::zero());
     29 }