about summary refs log tree commit diff
path: root/src/libstd/sys/windows
diff options
context:
space:
mode:
authorkennytm <kennytm@gmail.com>2018-04-07 14:51:28 +0800
committerGitHub <noreply@github.com>2018-04-07 14:51:28 +0800
commit496f02677525ce2f779af17057959eadb0b1ac6a (patch)
tree329aab1628553b4bf64b44124b38b9c5c348ed7f /src/libstd/sys/windows
parent91e81fa2a3a20fd9d6c25205e27ce17976faedea (diff)
parent323f8087910b0d63815003970bb8a45e3ccfdb17 (diff)
downloadrust-496f02677525ce2f779af17057959eadb0b1ac6a.tar.gz
rust-496f02677525ce2f779af17057959eadb0b1ac6a.zip
Rollup merge of #49702 - alexcrichton:inline-methods, r=Mark-Simulacrum
std: Inline some Termination-related methods

These were showing up in tests and in binaries but are trivially optimize-able
away, so add `#[inline]` attributes so LLVM has an opportunity to optimize them
out.
Diffstat (limited to 'src/libstd/sys/windows')
-rw-r--r--src/libstd/sys/windows/process.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/libstd/sys/windows/process.rs b/src/libstd/sys/windows/process.rs
index afa8e3e1369..bd5507e8f89 100644
--- a/src/libstd/sys/windows/process.rs
+++ b/src/libstd/sys/windows/process.rs
@@ -414,6 +414,7 @@ impl ExitCode {
     pub const SUCCESS: ExitCode = ExitCode(EXIT_SUCCESS as _);
     pub const FAILURE: ExitCode = ExitCode(EXIT_FAILURE as _);
 
+    #[inline]
     pub fn as_i32(&self) -> i32 {
         self.0 as i32
     }