rt: rename nano_time() builtin to match time::precise_time_ns()

This commit is contained in:
Chris Peterson 2012-02-18 01:39:42 -08:00
parent b73bc30858
commit 3d202d7eae
3 changed files with 4 additions and 4 deletions

View File

@ -5,7 +5,7 @@ Module: time
#[abi = "cdecl"]
native mod rustrt {
fn get_time(&sec: u32, &usec: u32);
fn nano_time(&ns: u64);
fn precise_time_ns(&ns: u64);
}
/*
@ -34,7 +34,7 @@ Function: precise_time_ns
Returns the current value of a high-resolution performance counter
in nanoseconds since an unspecified epoch.
*/
fn precise_time_ns() -> u64 { let ns = 0u64; rustrt::nano_time(ns); ret ns; }
fn precise_time_ns() -> u64 { let ns = 0u64; rustrt::precise_time_ns(ns); ns }
/*
Function: precise_time_s

View File

@ -420,7 +420,7 @@ get_time(uint32_t *sec, uint32_t *usec) {
#endif
extern "C" CDECL void
nano_time(uint64_t *ns) {
precise_time_ns(uint64_t *ns) {
timer t;
*ns = t.time_ns();
}

View File

@ -13,10 +13,10 @@ get_port_id
get_task_id
get_time
last_os_error
nano_time
new_port
new_task
port_recv
precise_time_ns
rust_port_select
rand_free
rand_new