From eac178a2dea0857d91838b54844e74285b5957c6 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Wed, 20 May 2020 13:19:49 +0300 Subject: Vector of optional movable-only elements --- tests/optional/driver.cxx | 19 ++++--------------- 1 file changed, 4 insertions(+), 15 deletions(-) diff --git a/tests/optional/driver.cxx b/tests/optional/driver.cxx index 5dd8964..e63c985 100644 --- a/tests/optional/driver.cxx +++ b/tests/optional/driver.cxx @@ -20,7 +20,6 @@ import butl.optional; #endif using namespace std; -using namespace butl; struct redirect { @@ -33,22 +32,12 @@ struct redirect redirect& operator= (const redirect&) = delete; }; -struct command -{ - butl::optional err; -}; - int main () { - /*( - command c; - vector cs; - cs.emplace_back (move (c)); -// cs.push_back (move (c)); -*/ - - redirect r; - vector rs; + using butl::optional; + + optional r; + vector> rs; rs.emplace_back (move (r)); } -- cgit v1.1