vector<string>& temp = var_obj.funct();
is not working in Linux but except &
ITS WORKING FINE.
vector<string> temp = var_obj.funct();
error : invalid initialization of non-const reference of type ‘std::vector, std::allocator >, std::allocator, std::allocator > > >&’ from a temporary of type ‘std::vector, std::allocator >, std::allocator, std::allocator > > >’