Skip to content

Add top-level channel module? #445

Closed
@matklad

Description

@matklad

Currently, channel, Sender and Receiver live directly in async_std::sync. This doesn't match std (where there's a sync::mpsc submodule) and looks pretty weird on it's own:

  • I expect sync::channel to be a module (to the point that I was thinking about it as such when writing a title for this issue, despite the fact that I've used this function a minute ago)
  • Knowing that sync::channel is a function, I need to refer to example to recall where should I find Sender and Receiver types.

Top-level async_std::channel would make more sense to me personally. It diverges from the standard tradition of piling everything into the sync module, but it is rumored that std::sync might be split itself.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions