From d1d2aa22c0d15465af1daccdb3821450c98d0ed0 Mon Sep 17 00:00:00 2001 From: Mazdak Farrokhzad Date: Tue, 23 Oct 2018 18:06:11 +0200 Subject: reduce list to functions callable in const ctx. --- src/libstd/ffi/c_str.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/libstd/ffi') diff --git a/src/libstd/ffi/c_str.rs b/src/libstd/ffi/c_str.rs index feff65bff3f..e2dc02e40bf 100644 --- a/src/libstd/ffi/c_str.rs +++ b/src/libstd/ffi/c_str.rs @@ -833,7 +833,7 @@ impl NulError { /// assert_eq!(nul_error.nul_position(), 7); /// ``` #[stable(feature = "rust1", since = "1.0.0")] - pub const fn nul_position(&self) -> usize { self.0 } + pub fn nul_position(&self) -> usize { self.0 } /// Consumes this error, returning the underlying vector of bytes which /// generated the error in the first place. @@ -909,7 +909,7 @@ impl IntoStringError { /// Access the underlying UTF-8 error that was the cause of this error. #[stable(feature = "cstring_into", since = "1.7.0")] - pub const fn utf8_error(&self) -> Utf8Error { + pub fn utf8_error(&self) -> Utf8Error { self.error } } -- cgit 1.4.1-3-g733a5