void*Foo(inta)__attribute__((alloc_align(1)));// expected-error {{'alloc_align' attribute is invalid for the implicit this argument}}
};
template<typenameT>
structdependent_ret{
T*Foo(inta)__attribute__((alloc_align(2)));// no-warning, ends up being int**.
TFoo2(inta)__attribute__((alloc_align(2)));// expected-warning {{'alloc_align' attribute only applies to return values that are pointers or references}}
};
// Following 2 errors associated only with the 'float' versions below.
template<typenameT>
structdependent_param_struct{
void*Foo(Tparam)__attribute__((alloc_align(2)));// expected-error {{'alloc_align' attribute argument may only refer to a function parameter of integer type}}
};
template<typenameT>
void*dependent_param_func(Tparam)__attribute__((alloc_align(1)));// expected-error {{'alloc_align' attribute argument may only refer to a function parameter of integer type}}
template<intT>
void*illegal_align_param(intp)__attribute__((alloc_align(T)));// expected-error {{'alloc_align' attribute requires parameter 1 to be an integer constant}}