summaryrefslogtreecommitdiff
path: root/rust_src.patch
diff options
context:
space:
mode:
authorJohn Hodge <tpg@mutabah.net>2018-10-03 20:50:30 +0800
committerJohn Hodge <tpg@mutabah.net>2018-10-03 20:50:30 +0800
commite42b7877ac1f7c173d42600b220b1f50a143b9b4 (patch)
treeeeb7f627f831de64446c18bf108c5a1297f5ee13 /rust_src.patch
parent9fe41ffb9bde218ad97c5430d6cc92051634357d (diff)
downloadmrust-e42b7877ac1f7c173d42600b220b1f50a143b9b4.tar.gz
Fiddling for rustc 1.29 update
Diffstat (limited to 'rust_src.patch')
-rw-r--r--rust_src.patch26
1 files changed, 0 insertions, 26 deletions
diff --git a/rust_src.patch b/rust_src.patch
deleted file mode 100644
index 1cc13242..00000000
--- a/rust_src.patch
+++ /dev/null
@@ -1,26 +0,0 @@
---- src/libcore/intrinsics.rs
-+++ src/libcore/intrinsics.rs
-@@ -678,5 +678,9 @@
- pub fn min_align_of_val<T: ?Sized>(_: &T) -> usize;
-
-+ /// Obtain the length of a slice pointer
-+ #[cfg(rust_compiler="mrustc")]
-+ pub fn mrustc_slice_len<T>(pointer: *const [T]) -> usize;
-+
- /// Gets a static string slice containing the name of a type.
- pub fn type_name<T: ?Sized>() -> &'static str;
-
---- src/libcore/slice/mod.rs
-+++ src/libcore/slice/mod.rs
-@@ -413,6 +413,8 @@
- #[inline]
- fn len(&self) -> usize {
-- unsafe {
-- mem::transmute::<&[T], Repr<T>>(self).len
-- }
-+ #[cfg(not(rust_compiler="mrustc"))]
-+ let rv = unsafe { mem::transmute::<&[T], Repr<T>>(self).len };
-+ #[cfg(rust_compiler="mrustc")]
-+ let rv = unsafe { ::intrinsics::mrustc_slice_len(self) };
-+ rv
- }