mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Remove rtinstrument (fixes #4600).
The code has been disabled during the last rust upgrade, and has not found an owner. Since the next rust upgrade will bitrot it even more, it is better to remove it for now. If anyone wishes to restore it, the code remains in version history.
This commit is contained in:
parent
024571dfa3
commit
ee4c56bd8b
4 changed files with 6 additions and 218 deletions
|
@ -6,13 +6,11 @@ use std::borrow::ToOwned;
|
|||
use std::task;
|
||||
use std::comm::Sender;
|
||||
use std::task::TaskBuilder;
|
||||
// use rtinstrument;
|
||||
use task_state;
|
||||
|
||||
pub fn spawn_named(name: String, f: proc():Send) {
|
||||
let builder = task::TaskBuilder::new().named(name);
|
||||
builder.spawn(proc() {
|
||||
// rtinstrument::instrument(f);
|
||||
f();
|
||||
});
|
||||
}
|
||||
|
@ -25,22 +23,18 @@ pub fn spawn_named_with_send_on_failure<T: Send>(name: &'static str,
|
|||
dest: Sender<T>) {
|
||||
let future_result = TaskBuilder::new().named(name).try_future(proc() {
|
||||
task_state::initialize(state);
|
||||
// FIXME: Find replacement for this post-runtime removal
|
||||
// rtinstrument::instrument(f);
|
||||
f();
|
||||
});
|
||||
|
||||
let watched_name = name.to_owned();
|
||||
let watcher_name = format!("{}Watcher", watched_name);
|
||||
TaskBuilder::new().named(watcher_name).spawn(proc() {
|
||||
//rtinstrument::instrument(proc() {
|
||||
match future_result.into_inner() {
|
||||
Ok(()) => (),
|
||||
Err(..) => {
|
||||
debug!("{} failed, notifying constellation", name);
|
||||
dest.send(msg);
|
||||
}
|
||||
match future_result.into_inner() {
|
||||
Ok(()) => (),
|
||||
Err(..) => {
|
||||
debug!("{} failed, notifying constellation", name);
|
||||
dest.send(msg);
|
||||
}
|
||||
//});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue