Improve and simplify code with modern C++ features

Change-Id: I83bf5513c2a1f90ba5a59e93c473306864b27d94
diff --git a/tests/limited-io.cpp b/tests/limited-io.cpp
index 66a0946..9f8f4dc 100644
--- a/tests/limited-io.cpp
+++ b/tests/limited-io.cpp
@@ -56,8 +56,8 @@
 
   m_reason = NO_WORK;
   m_nOpsRemaining = nOpsLimit;
-  if (timeLimit >= time::nanoseconds::zero()) {
-    m_timeout = scheduler::schedule(timeLimit, bind(&LimitedIo::afterTimeout, this));
+  if (timeLimit >= 0_ns) {
+    m_timeout = scheduler::schedule(timeLimit, [this] { afterTimeout(); });
   }
 
   try {