summaryrefslogtreecommitdiffstats
path: root/test/SemaTemplate/function-template-specialization-noreturn.cpp
blob: 3e1f61855a507b7e6bdddc0e5e9befb84897effb (plain)
1
2
3
4
5
6
7
8
// RUN: %clang_cc1 -fsyntax-only -verify %s

// Split from function-template-specialization.cpp because the noreturn warning
// requires analysis-based warnings, which the other errors in that test case
// disable.

template <int N> void __attribute__((noreturn)) f3() { __builtin_unreachable(); }
template <> void f3<1>() { } // expected-warning {{function declared 'noreturn' should not return}}
OpenPOWER on IntegriCloud