Skip to content

[name bikeshed] This API is useful in both async and sync situations #24

Open
@pygy

Description

@pygy

This is IMO a much needed addition to the language, I love this proposal.

I wonder however if calling it AsyncContext is the best way to go about it, given that it is also useful in sync contexts, and could replace the try{}finally{} pattern described in the README in every situation.

While we're at it, given that this is already the context in JS, another term may be less confusing. I know that React also uses context for its dynamic scope construct, so there's also a precedent here... No strong opinions, just raising this in case we find something better.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions