From 9c60823871c50f5aad93ad73c4b16a0985fb4918 Mon Sep 17 00:00:00 2001 From: Joel Klinghed Date: Wed, 27 Sep 2017 19:54:18 +0200 Subject: Some really minor cleanups of io.hh --- src/io.hh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/io.hh b/src/io.hh index abd91fa..c39fa2e 100644 --- a/src/io.hh +++ b/src/io.hh @@ -8,16 +8,17 @@ namespace io { class pipe { public: pipe(); - pipe(pipe&& pipe); + pipe(pipe&& other); ~pipe(); - pipe& operator=(pipe&& pipe) { + pipe& operator=(pipe&& other) { reset(); - swap(pipe); + swap(other); return *this; } bool open(); + explicit operator bool() const { return read() != -1; } -- cgit v1.3