| //===----------------------------------------------------------------------===// |
| // The LLVM Compiler Infrastructure |
| // This file is dual licensed under the MIT and the University of Illinois Open |
| // Source Licenses. See LICENSE.TXT for details. |
| //===----------------------------------------------------------------------===// |
| // constexpr duration operator--(int); // constexpr in C++17 |
| constexpr bool test_constexpr() |
| std::chrono::hours h1(3); |
| std::chrono::hours h2 = h1--; |
| return h1.count() == 2 && h2.count() == 3; |
| std::chrono::hours h1(3); |
| std::chrono::hours h2 = h1--; |
| static_assert(test_constexpr(), ""); |