From b72ed5572f585cfc1771117739447f2f6dfa6785 Mon Sep 17 00:00:00 2001 From: Tim Chevalier Date: Fri, 4 Jan 2013 14:48:19 -0800 Subject: [PATCH] core: Allow set_buffer_ to be referred to as set-buffer After a snapshot, we can take out the set_buffer_ version (pipes syntax exts use it). As per #4421 --- src/libcore/gc.rs | 1 + src/libcore/pipes.rs | 7 +++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/libcore/gc.rs b/src/libcore/gc.rs index 8bb3610ffb4..886f2d1c083 100644 --- a/src/libcore/gc.rs +++ b/src/libcore/gc.rs @@ -347,6 +347,7 @@ pub fn cleanup_stack_for_failure() { if ptr::is_null(tydesc) { // FIXME #4420: Destroy this box + // FIXME #4330: Destroy this box } else { rustrt::rust_call_tydesc_glue(*root, tydesc, 3 as size_t); } diff --git a/src/libcore/pipes.rs b/src/libcore/pipes.rs index 2ff4effbd6e..c25a7a66c48 100644 --- a/src/libcore/pipes.rs +++ b/src/libcore/pipes.rs @@ -206,14 +206,17 @@ fn set_buffer(b: ~Buffer) unsafe { #[doc(hidden)] pub trait HasBuffer { - // FIXME #4421: This should not have a trailing underscore + fn set_buffer(b: *libc::c_void); + // FIXME #4421 remove after snapshot fn set_buffer_(b: *libc::c_void); } impl Packet: HasBuffer { - fn set_buffer_(b: *libc::c_void) { + fn set_buffer(b: *libc::c_void) { self.header.buffer = b; } + // FIXME #4421 remove after snapshot + fn set_buffer_(b: *libc::c_void) { self.set_buffer(b) } } #[doc(hidden)] -- GitLab