RustyLee Cleans up code formatting
Removes unnecessary line breaks and comments, improving code readability and consistency. Consolidates multi-line function signatures and variable declarations into single lines.
This commit is contained in:
parent
8195a3ccad
commit
33ae160566
1 changed files with 2 additions and 7 deletions
|
|
@ -18,10 +18,7 @@ impl OrganFactory {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl OrganFactory {
|
impl OrganFactory {
|
||||||
pub fn build_organs(
|
pub fn build_organs(brain_tx: Sender<BrainMessage>) -> Vec<OrganSocket> {
|
||||||
// The Brain's "Inbox" mouth - we'll clone this for each organ
|
|
||||||
brain_tx: Sender<BrainMessage>
|
|
||||||
) -> Vec<OrganSocket> {
|
|
||||||
let mut sockets = Vec::new();
|
let mut sockets = Vec::new();
|
||||||
let mut ids = 1..;
|
let mut ids = 1..;
|
||||||
|
|
||||||
|
|
@ -34,9 +31,7 @@ impl OrganFactory {
|
||||||
|
|
||||||
fn spawn_heart(id: u32, feedback_to_brain_tx: Sender<BrainMessage>) -> OrganSocket {
|
fn spawn_heart(id: u32, feedback_to_brain_tx: Sender<BrainMessage>) -> OrganSocket {
|
||||||
let initial_life_state = LifeState::Dead;
|
let initial_life_state = LifeState::Dead;
|
||||||
let (brain_command_to_organ_tx, brain_command_to_organ_rx) =
|
let (brain_command_to_organ_tx, brain_command_to_organ_rx) = Self::get_organ_channels();
|
||||||
Self::get_organ_channels();
|
|
||||||
|
|
||||||
let socket = OrganSocket::new(id, initial_life_state, brain_command_to_organ_tx);
|
let socket = OrganSocket::new(id, initial_life_state, brain_command_to_organ_tx);
|
||||||
|
|
||||||
thread::spawn(move || {
|
thread::spawn(move || {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue