This template function doesn’t seem to be properly highlighted. Build 3176.
template<typename T> container<bar<T>> foo(T t)
{
return container<bar<T>> { item<bar<T>>(t) };
}
It seems to wrongly tell the last curly brace is surplus, which is not. The code compiles smoothly.
The crux seems to be linked with <bar<T>>
.
To explain the code, it generates a container
object list initializing with just one item
, which is from a template class, with compound type <bar<T>>
.
Please take a look. Thanks.