Skip to content

Dart should support &&= and ||= operators. #122

Open
@lrhn

Description

@lrhn

Dart does not currently support using the && and || operators in assignments.
It allows other non-short-circuiting binary operators, and it allows ??=, which is short-circuiting.
Users have expressed surprise that those two are not supported.

This is a solution to #23.

See https://dart-review.googlesource.com/c/sdk/+/43500/ for a specification.

Metadata

Metadata

Assignees

No one assigned

    Labels

    featureProposed language feature that solves one or more problemssmall-featureA small feature which is relatively cheap to implement.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions