about summary refs log tree commit diff
path: root/src/libstd
diff options
context:
space:
mode:
authorThayne McCombs <astrothayne@gmail.com>2017-10-07 20:59:58 -0600
committerThayne McCombs <astrothayne@gmail.com>2017-10-07 20:59:58 -0600
commit29b319b6b20bb8e18b7e3c14528f9933de2f5e92 (patch)
tree2c1359562f3f3d86b33b092cfb9c54ca59ef144c /src/libstd
parentba7575886e6a294b8185f51a1701574f72abe5a8 (diff)
Change current_pid to just `id`.
Diffstat (limited to 'src/libstd')
-rw-r--r--src/libstd/process.rs7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/libstd/process.rs b/src/libstd/process.rs
index 711d8df1b60..dee01df651d 100644
--- a/src/libstd/process.rs
+++ b/src/libstd/process.rs
@@ -1174,14 +1174,15 @@ pub fn abort() -> ! {
 /// Basic usage:
 ///
 /// ```no_run
-/// use std::process::current_pid;
+/// #![feature(getpid)]
+/// use std::process;
 ///
-/// println!("My pid is {}", current_pid());
+/// println!("My pid is {}", process::id());
 /// ```
 ///
 ///
 #[unstable(feature = "getpid", issue = "44971", reason = "recently added")]
-pub fn current_pid() -> u32 {
+pub fn id() -> u32 {
     ::sys::os::getpid()
 }