mirror of
https://github.com/intel/llvm.git
synced 2026-01-13 11:02:04 +08:00
[libc++][test] Fix-up tests for is_clock(_v) (#166888)
This fixes incompleteness and inconsistency for test files added in
adc7932461, by
- renaming
`libcxx/test/std/time/time.traits.is.clock/trait.is.clock.compile.pass.cpp`
to `libcxx/test/std/time/time.traits/is.clock.compile.pass.cpp`,
- renaming
`libcxx/test/libcxx/time/time.traits.is.clock/trait.is.clock.compile.verify.cpp`
to `libcxx/test/libcxx/time/time.traits/is.clock.verify.cpp` , and
- adding comments clarifying what are being tested.
This commit is contained in:
@@ -8,6 +8,18 @@
|
||||
|
||||
// REQUIRES: std-at-least-c++20
|
||||
|
||||
// <chrono>
|
||||
//
|
||||
// template<class T> struct is_clock;
|
||||
// template<class T> constexpr bool is_clock_v = is_clock<T>::value;
|
||||
|
||||
// [time.traits.is.clock]/3:
|
||||
// The behavior of a program that adds specializations for is_clock is undefined.
|
||||
|
||||
// [namespace.std]/3:
|
||||
// The behavior of a C++ program is undefined if it declares an explicit or partial specialization of any standard
|
||||
// library variable template, except where explicitly permitted by the specification of that variable template.
|
||||
|
||||
#include <chrono>
|
||||
#include <ratio>
|
||||
|
||||
@@ -8,6 +8,11 @@
|
||||
|
||||
// REQUIRES: std-at-least-c++20
|
||||
|
||||
// <chrono>
|
||||
//
|
||||
// template<class T> struct is_clock;
|
||||
// template<class T> constexpr bool is_clock_v = is_clock<T>::value;
|
||||
|
||||
#include <chrono>
|
||||
#include <ratio>
|
||||
|
||||
Reference in New Issue
Block a user