blob: 8e8e7559320ca330b01af7c4891cf19f13dedffd [file] [log] [blame]
Marshall Clow1c7fe122016-11-14 18:22:19 +00001//===----------------------------------------------------------------------===//
2//
Chandler Carruth57b08b02019-01-19 10:56:40 +00003// 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
Marshall Clow1c7fe122016-11-14 18:22:19 +00006//
7//===----------------------------------------------------------------------===//
Stephan T. Lavavejd72ece62016-11-23 22:03:28 +00008//
Marshall Clow1c7fe122016-11-14 18:22:19 +00009// UNSUPPORTED: c++98, c++03, c++11, c++14
10// <numeric>
11
12// template<class _M, class _N>
13// constexpr common_type_t<_M,_N> gcd(_M __m, _N __n)
14
Stephan T. Lavavejd72ece62016-11-23 22:03:28 +000015// Remarks: If either M or N is not an integer type,
Marshall Clow1c7fe122016-11-14 18:22:19 +000016// or if either is (a possibly cv-qualified) bool, the program is ill-formed.
17
18#include <numeric>
19
20
21int main()
22{
23 std::gcd<int, const bool>(2, true);
24}