We can't declare unique_function that has in its arguments a reference to
a template type with an incomplete argument.
For instance, we can't declare unique_function<void(SmallVectorImpl<A>&)>
when A is forward declared.
This is because SFINAE will trigger a hard error in this case, when instantiating
IsSizeLessThanThresholdT with the incomplete type.
This patch specialize AdjustedParamT for references to remove this error.
std::is_reference is true not only for l-value references, i.e. if you try adding static_assert(!std::is_reference<T>::value); after this declaration, it'll fail. So it'd be probably better to keep that.
Also please add static_assert(!std::is_lvalue_reference<T>::value); to make the intentions clear.