Sign in
gnu
/
gcc
/
ab810952eb7c061e37054ddd1dfe0aa033365131
/
.
/
gcc
/
testsuite
/
g++.dg
/
cpp1z
/
constexpr-if19.C
blob: a1eaf320221f4930d4758a14d673a2e5828ea123 [
file
] [
log
] [
blame
]
// PR c++/85200
// { dg-do compile { target c++17 } }
struct
A
{
constexpr
operator
int
(){
return
0
;
}
};
template
<
typename
>
void
f
(){
[](
auto
known
){
if
constexpr
(
constexpr
int
k
=
known
);
}(
A
{});
}
int
main
(){
f
<int>
();
}