You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
12 lines
493 B
12 lines
493 B
// RUN: %clang_analyze_cc1 -analyzer-checker=core -std=c++11 -fdelayed-template-parsing -verify %s
|
|
// expected-no-diagnostics
|
|
|
|
template <class T> struct remove_reference {typedef T type;};
|
|
template <class T> struct remove_reference<T&> {typedef T type;};
|
|
template <class T> struct remove_reference<T&&> {typedef T type;};
|
|
|
|
template <typename T>
|
|
typename remove_reference<T>::type&& move(T&& arg) { // this used to crash
|
|
return static_cast<typename remove_reference<T>::type&&>(arg);
|
|
}
|