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.
24 lines
487 B
24 lines
487 B
// RUN: %clang_cc1 -fsyntax-only -verify %s
|
|
// expected-no-diagnostics
|
|
|
|
__attribute__((objc_root_class))
|
|
@interface Root
|
|
@end
|
|
|
|
@class Forward;
|
|
|
|
template <class T> void destroyPointer(T *t) {
|
|
t->~T();
|
|
}
|
|
|
|
template <class T> void destroyReference(T &t) {
|
|
t.~T();
|
|
}
|
|
|
|
template void destroyPointer<Root*>(Root **);
|
|
template void destroyReference<Root*>(Root *&);
|
|
|
|
// rdar://18522255
|
|
template void destroyPointer<Forward*>(Forward **);
|
|
template void destroyReference<Forward*>(Forward *&);
|