Skip to content

Documentation: Calling wait on empty selection structure hangs, does not panic #22266

@laumann

Description

@laumann

In the documentation for Select it reads:

/// Creates a new selection structure. This set is initially empty and
/// `wait` will panic!() if called.

but the following program does not panic, it simply hangs.

use std::sync::mpsc::Select;
fn main() {
    Select::new().wait();
}

rustc version:

rustc 1.0.0-dev (1500df893 2015-02-11 08:54:30 +0000)
binary: rustc
commit-hash: 1500df8934431dd7842827209528211ae53ded12
commit-date: 2015-02-11 08:54:30 +0000
host: x86_64-unknown-linux-gnu
release: 1.0.0-dev

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions