Skip to content

Commit

Permalink
Auto merge of #279 - ferivoz:typos, r=jdm
Browse files Browse the repository at this point in the history
Fix typos

Typos found with codespell
  • Loading branch information
bors-servo committed Nov 21, 2021
2 parents a7e5534 + 8bd058d commit 589a62c
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions src/ipc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ impl StdError for TryRecvError {
}

/// Create a connected [IpcSender] and [IpcReceiver] that
/// transfer messages of a given type privided by type `T`
/// transfer messages of a given type provided by type `T`
/// or inferred by the types of messages sent by the sender.
///
/// Messages sent by the sender will be available to the
Expand Down Expand Up @@ -204,7 +204,7 @@ pub fn bytes_channel() -> Result<(IpcBytesSender, IpcBytesReceiver), io::Error>
/// loop {
/// match rx.try_recv() {
/// Ok(res) => {
/// // Do something interesting wth your result
/// // Do something interesting with your result
/// println!("Received data...");
/// break;
/// },
Expand Down Expand Up @@ -353,7 +353,7 @@ impl<T> IpcSender<T> where T: Serialize {
})
}

/// Send data accross the channel to the receiver.
/// Send data across the channel to the receiver.
pub fn send(&self, data: T) -> Result<(), bincode::Error> {
let mut bytes = Vec::with_capacity(4096);
OS_IPC_CHANNELS_FOR_SERIALIZATION.with(|os_ipc_channels_for_serialization| {
Expand Down
2 changes: 1 addition & 1 deletion src/platform/inprocess/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ impl OsIpcReceiverSet {

struct Remove(usize, u64);

// FIXME: Remove early returns and explictly drop `borrows` when lifetimes are non-lexical
// FIXME: Remove early returns and explicitly drop `borrows` when lifetimes are non-lexical
let Remove(r_index, r_id) = {
let borrows: Vec<_> = self.receivers.iter().map(|r| {
Ref::map(r.receiver.borrow(), |o| o.as_ref().unwrap())
Expand Down
4 changes: 2 additions & 2 deletions src/platform/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -978,7 +978,7 @@ fn try_recv_large_delayed() {
time_per_run = start.elapsed();
}
// This assumes time_per_run stays below one second.
// Unless something weird happens, we shoud be safely within this margin...
// Unless something weird happens, we should be safe within this margin...
iterations_per_ms = iterations * 1_000_000 / time_per_run.subsec_nanos() as u64;
}

Expand Down Expand Up @@ -1116,7 +1116,7 @@ fn cross_process_two_step_transfer_spawn() {
let sub_tx = received_channels[0].to_sender();

// Send the outer payload channel, so the server can use it to
// retrive the inner payload and the cookie
// retrieve the inner payload and the cookie
sub_tx.send(&[], vec![OsIpcChannel::Receiver(two_rx)], vec![]).unwrap();

// Then we wait for the cookie to make its way back to us
Expand Down
2 changes: 1 addition & 1 deletion src/platform/windows/aliased_cell.rs
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ impl Drop for DropBomb {
/// Leaking the memory, while undesirable in general,
/// keeps the memory accessible to any outstanding aliases.
/// This is the only way to retain soundness during unwinding,
/// or when the panic gets catched.
/// or when the panic gets caught.
///
/// Note that making FFI access through untracked aliases
/// requires the value to have a stable memory location --
Expand Down
2 changes: 1 addition & 1 deletion src/platform/windows/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ impl<'data> Message<'data> {
/// make sure that the message was originally sent to it, and was not sitting
/// in another channel's buffer when that channel got transferred to another
/// process. On Windows, we duplicate handles on the sender side to a specific
/// reciever. If the wrong receiver gets it, those handles are not valid.
/// receiver. If the wrong receiver gets it, those handles are not valid.
///
/// TODO(vlad): We could attempt to recover from the above situation by
/// duplicating from the intended target process to ourselves (the receiver).
Expand Down
2 changes: 1 addition & 1 deletion src/router.rs
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ impl Router {
}
}

/// Continously loop waiting for wakeup signals from router proxy.
/// Continuously loop waiting for wakeup signals from router proxy.
/// Iterate over events either:
/// 1) If a message comes in from our special `wakeup_receiver` (identified through
/// msg_wakeup_id. Read message from `msg_receiver` and add a new receiver
Expand Down

0 comments on commit 589a62c

Please sign in to comment.