From 7a6b891a29fde4b93b3037757958b0652a8446fa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= Date: Sun, 10 Sep 2017 16:57:09 +0200 Subject: [PATCH] hashglobe: Inline error constructor so we don't pay a function call even when there's no error. --- components/hashglobe/src/lib.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/components/hashglobe/src/lib.rs b/components/hashglobe/src/lib.rs index 8c107148066..cbbdacb4c8d 100644 --- a/components/hashglobe/src/lib.rs +++ b/components/hashglobe/src/lib.rs @@ -34,6 +34,7 @@ pub struct FailedAllocationError { } impl FailedAllocationError { + #[inline] pub fn new(reason: &'static str) -> Self { Self { reason } }