[iolib-devel] Additions to iolib-posix

Faré fahree at gmail.com
Wed May 2 19:59:29 UTC 2007


;; (1) this code should be moved to iolib-posix and exported under some name...
(defun fsleep (delay)
  (when (plusp delay)
    (multiple-value-bind (i d) (floor delay)
      (unless (zerop i)
        ;; TODO: here insert check for overflow...
        (et::sleep i))
      (unless (zerop d)
        (et::usleep (floor (* d 1000000))))))
  nil)

;; (2) et::gettime should be exported

;; (3) unless we don't care about the inefficiency of calling gettime
many times, we should expose the deadline in polling, etc., because
that's what the application wants, anyway. At least mine.

[ François-René ÐVB Rideau | Reflection&Cybernethics | http://fare.tunes.org ]
The hacker: someone who figured things out and made something cool happen.
        -- Alan Schmitt



More information about the iolib-devel mailing list