Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Register new snapshots #10160

Merged
merged 1 commit into from
Oct 30, 2013
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 7 additions & 11 deletions mk/stage0.mk
Original file line number Diff line number Diff line change
Expand Up @@ -98,17 +98,13 @@ $$(HLIB0_H_$(1))/$(CFG_EXTRALIB_$(1)): \
$$(Q)cp $$(TLIB$(2)_T_$(1)_H_$(3))/$(EXTRALIB_GLOB_$(1)) $$@
$$(call LIST_ALL_OLD_GLOB_MATCHES_EXCEPT,$$(dir $$@),$(EXTRALIB_GLOB_$(4)),$$(notdir $$@))

$$(HLIB0_H_$(1))/$(CFG_LIBRUSTUV_$(1)):
touch $$@
# NOTE: this should get uncommented after a snapshot and the rule above this can
# get deleted, right now we're not expecting a librustuv in a snapshot.
# $$(HLIB0_H_$(1))/$(CFG_LIBRUSTUV_$(1)): \
# $$(TLIB$(2)_T_$(1)_H_$(3))/$(CFG_LIBRUSTUV_$(1)) \
# | $(HLIB0_H_$(1))/
# @$$(call E, cp: $$@)
# $$(call CHECK_FOR_OLD_GLOB_MATCHES_EXCEPT,$$(dir $$@),$(LIBRUSTUV_GLOB_$(4)),$$(notdir $$@))
# $$(Q)cp $$(TLIB$(2)_T_$(1)_H_$(3))/$(LIBRUSTUV_GLOB_$(1)) $$@
# $$(call LIST_ALL_OLD_GLOB_MATCHES_EXCEPT,$$(dir $$@),$(LIBRUSTUV_GLOB_$(4)),$$(notdir $$@))
$$(HLIB0_H_$(1))/$(CFG_LIBRUSTUV_$(1)): \
$$(TLIB$(2)_T_$(1)_H_$(3))/$(CFG_LIBRUSTUV_$(1)) \
| $(HLIB0_H_$(1))/
@$$(call E, cp: $$@)
$$(call CHECK_FOR_OLD_GLOB_MATCHES_EXCEPT,$$(dir $$@),$(LIBRUSTUV_GLOB_$(4)),$$(notdir $$@))
$$(Q)cp $$(TLIB$(2)_T_$(1)_H_$(3))/$(LIBRUSTUV_GLOB_$(1)) $$@
$$(call LIST_ALL_OLD_GLOB_MATCHES_EXCEPT,$$(dir $$@),$(LIBRUSTUV_GLOB_$(4)),$$(notdir $$@))

$$(HLIB0_H_$(1))/$(CFG_LIBRUSTC_$(1)): \
$$(TLIB$(2)_T_$(1)_H_$(3))/$(CFG_LIBRUSTC_$(1)) \
Expand Down
7 changes: 3 additions & 4 deletions src/librustuv/rustuv.rs
Original file line number Diff line number Diff line change
Expand Up @@ -232,15 +232,14 @@ impl<H, W: Watcher + NativeHandle<*H>> WatcherInterop for W {
}
}

fn close(self, cb: NullCallback) {
let mut this = self;
fn close(mut self, cb: NullCallback) {
{
let data = this.get_watcher_data();
let data = self.get_watcher_data();
assert!(data.close_cb.is_none());
data.close_cb = Some(cb);
}

unsafe { uvll::close(this.native_handle(), close_cb); }
unsafe { uvll::close(self.native_handle(), close_cb); }

extern fn close_cb(handle: *uvll::uv_handle_t) {
let mut h: Handle = NativeHandle::from_native_handle(handle);
Expand Down
9 changes: 4 additions & 5 deletions src/librustuv/uvio.rs
Original file line number Diff line number Diff line change
Expand Up @@ -122,10 +122,9 @@ trait HomingIO {
a // return the result of the IO
}

fn home_for_io_consume<A>(self, io: &fn(Self) -> A) -> A {
let mut this = self;
let home = this.go_to_IO_home();
let a = io(this); // do IO
fn home_for_io_consume<A>(mut self, io: &fn(Self) -> A) -> A {
let home = self.go_to_IO_home();
let a = io(self); // do IO
HomingIO::restore_original_home(None::<Self>, home);
a // return the result of the IO
}
Expand Down Expand Up @@ -239,7 +238,7 @@ impl EventLoop for UvEventLoop {
}
}

#[cfg(not(stage0), not(test))]
#[cfg(not(test))]
#[lang = "event_loop_factory"]
pub extern "C" fn new_loop() -> ~EventLoop {
~UvEventLoop::new() as ~EventLoop
Expand Down
15 changes: 0 additions & 15 deletions src/libstd/rt/crate_map.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ use container::MutableSet;
use hashmap::HashSet;
use option::{Some, None, Option};
use vec::ImmutableVector;
#[cfg(not(stage0))]
use rt::rtio::EventLoop;

// Need to tell the linker on OS X to not barf on undefined symbols
Expand All @@ -27,14 +26,6 @@ pub struct ModEntry<'self> {
log_level: *mut u32
}

#[cfg(stage0)]
pub struct CrateMap<'self> {
version: i32,
entries: &'self [ModEntry<'self>],
children: &'self [&'self CrateMap<'self>]
}

#[cfg(not(stage0))]
pub struct CrateMap<'self> {
version: i32,
entries: &'self [ModEntry<'self>],
Expand All @@ -45,12 +36,6 @@ pub struct CrateMap<'self> {
#[cfg(not(windows))]
pub fn get_crate_map() -> Option<&'static CrateMap<'static>> {
extern {
#[cfg(stage0)]
#[weak_linkage]
#[link_name = "_rust_crate_map_toplevel"]
static CRATE_MAP: CrateMap<'static>;

#[cfg(not(stage0))]
#[crate_map]
static CRATE_MAP: CrateMap<'static>;
}
Expand Down
11 changes: 0 additions & 11 deletions src/libstd/rt/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,6 @@ pub mod io;
/// The EventLoop and internal synchronous I/O interface.
pub mod rtio;

/// libuv and default rtio implementation.
#[cfg(stage0)]
pub mod uv;

/// The Local trait for types that are accessible via thread-local
/// or task-local storage.
pub mod local;
Expand Down Expand Up @@ -463,13 +459,6 @@ pub fn in_green_task_context() -> bool {
}
}

#[cfg(stage0)]
pub fn new_event_loop() -> ~rtio::EventLoop {
use rt::uv::uvio::UvEventLoop;
~UvEventLoop::new() as ~rtio::EventLoop
}

#[cfg(not(stage0))]
pub fn new_event_loop() -> ~rtio::EventLoop {
#[fixed_stack_segment]; #[allow(cstack)];

Expand Down
Loading