about summary refs log tree commit diff
diff options
context:
space:
mode:
authorRichard Wiedenhöft <richard@wiedenhoeft.xyz>2019-04-29 15:49:43 +0200
committerRichard Wiedenhöft <richard@wiedenhoeft.xyz>2019-05-14 09:40:10 +0200
commita7a05203f18eac663ebf2751b77621c453dc280c (patch)
tree285a48d6a15372c3bf78c57e40ca7acf0746c8d3
parent80e7cde2238e837a9d6a240af9a3253f469bb2cf (diff)
downloadrust-a7a05203f18eac663ebf2751b77621c453dc280c.tar.gz
rust-a7a05203f18eac663ebf2751b77621c453dc280c.zip
Mark core::alloc::Layout::from_size_align_unchecked const
-rw-r--r--src/libcore/alloc.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libcore/alloc.rs b/src/libcore/alloc.rs
index c124457118c..302a9d89e58 100644
--- a/src/libcore/alloc.rs
+++ b/src/libcore/alloc.rs
@@ -99,7 +99,7 @@ impl Layout {
     /// [`Layout::from_size_align`](#method.from_size_align).
     #[stable(feature = "alloc_layout", since = "1.28.0")]
     #[inline]
-    pub unsafe fn from_size_align_unchecked(size: usize, align: usize) -> Self {
+    pub const unsafe fn from_size_align_unchecked(size: usize, align: usize) -> Self {
         Layout { size_: size, align_: NonZeroUsize::new_unchecked(align) }
     }