1//===----------------------------------------------------------------------===//
2//
3//                     The LLVM Compiler Infrastructure
4//
5// This file is dual licensed under the MIT and the University of Illinois Open
6// Source Licenses. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9
10// <memory>
11
12// shared_ptr
13
14// template<class CharT, class Traits, class Y>
15//   basic_ostream<CharT, Traits>&
16//   operator<<(basic_ostream<CharT, Traits>& os, shared_ptr<Y> const& p);
17
18#include <memory>
19#include <sstream>
20#include <cassert>
21
22int main()
23{
24    std::shared_ptr<int> p(new int(3));
25    std::ostringstream os;
26    assert(os.str().empty());
27    os << p;
28    assert(!os.str().empty());
29}
30