Home | History | Annotate | Download | only in optional.object.assign

Lines Matching refs:opt

44         optional<int> opt;
45 opt = 1;
46 assert(static_cast<bool>(opt) == true);
47 assert(*opt == 1);
50 optional<int> opt;
52 opt = i;
53 assert(static_cast<bool>(opt) == true);
54 assert(*opt == i);
57 optional<int> opt(3);
59 opt = i;
60 assert(static_cast<bool>(opt) == true);
61 assert(*opt == i);
64 optional<const AllowConstAssign> opt;
66 opt = other;
69 optional<std::unique_ptr<int>> opt;
70 opt = std::unique_ptr<int>(new int(3));
71 assert(static_cast<bool>(opt) == true);
72 assert(**opt == 3);
75 optional<std::unique_ptr<int>> opt(std::unique_ptr<int>(new int(2)));
76 opt = std::unique_ptr<int>(new int(3));
77 assert(static_cast<bool>(opt) == true);
78 assert(**opt == 3);