[llvm-gsymutil] Disable test macho-gsym-merged-callsites-dsym (#119957)
[llvm-project.git] / libcxx / test / std / time / time.duration / time.duration.cons / convert_float_to_int.compile.fail.cpp
blob4311c1bde38315d7bca65a10b74bf26f1fcf075f
1 //===----------------------------------------------------------------------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
9 // <chrono>
11 // duration
13 // template <class Rep2, class Period2>
14 // duration(const duration<Rep2, Period2>& d);
16 // conversions from floating point to integral durations disallowed
18 #include <chrono>
20 int main(int, char**)
22 std::chrono::duration<double> d;
23 std::chrono::duration<int> i = d;
25 return 0;