docs: function timeout(milliseconds, x) {
    return new promise.Promise(function(resolve, reject) {
      var abort = timer(milliseconds, function() {
        reject(new TimeoutError('Timed out after ' + milliseconds + 'ms'));
      });
  
      promise.Promise.from(x)
        .tap(resolve, reject)
        .ensure(abort);
  
      return abort;
    });
  }