nano_time 0.1.0

Function to get the number of nanoseconds since an unspecified epoch
docs.rs failed to build nano_time-0.1.0
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.

nanotime-rs

Simple function to get the system time in nanoseconds relative to an unspecified epoch. Pretty much the same functionality as Java's System.nanoTime().

The code was simply copied from rust-lang/time and cleaned up to just provide the nano_time function with no unneccessary dependencies.

Example

extern crate nano_time;

fn main() {
    let start = nano_time::nano_time();
    do_something();
    let end = nano_time::nano_time();
    println!("do_something() took {} nanoseconds.", (end-start));
}