mirror of
https://github.com/llvm/llvm-project.git
synced 2025-04-17 04:16:46 +00:00

See discussion in D51650, this change was a little aggressive in an error while doing a 'while we were here', so this removes that error condition, as it is apparently useful. This reverts commit bb4934601d731465e01e2e22c80ce2dbe687d73f.
12 lines
558 B
C++
12 lines
558 B
C++
// RUN: %clang_cc1 -triple x86_64-linux-gnu -fsyntax-only -verify -fexceptions -fcxx-exceptions %s -std=c++14
|
|
|
|
// expected-error@+2 {{attribute 'target_clones' multiversioned functions do not yet support function templates}}
|
|
template<typename T, typename U>
|
|
int __attribute__((target_clones("sse4.2", "default"))) foo(){ return 1;}
|
|
|
|
void uses_lambda() {
|
|
// expected-error@+1 {{attribute 'target_clones' multiversioned functions do not yet support lambdas}}
|
|
auto x = []()__attribute__((target_clones("sse4.2", "arch=ivybridge", "default"))) {};
|
|
x();
|
|
}
|