lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

On Tue, Oct 11, 2011 at 12:42 PM, Louis Mamakos <> wrote:
> How about an API that looked like this:
> seconds, fractional_seconds = foo.time()
> You'd return integer seconds as the first return value, and fractional
> seconds (as a floating point number) as the second result.  Code that was

I prefer to just return the time as a single number, with decimal
precision. lusocket has

It has (theoretically) nanosecond resolution on windows, and
millisecond on unix.

And, of course, I wrote my own before noticing that it existed:, lnet_gettimeofday()

I bet luaposix has one, too.