Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Wildcard Variables] Experiment Flag #55654

Open
1 of 4 tasks
Tracked by #55673
kallentu opened this issue May 6, 2024 · 3 comments
Open
1 of 4 tasks
Tracked by #55673

[Wildcard Variables] Experiment Flag #55654

kallentu opened this issue May 6, 2024 · 3 comments
Assignees
Labels
area-language Dart language related items (some items might be better tracked at github.com/dart-lang/language). feature-wildcard-variables Implementation of the wildcard variables feature

Comments

@kallentu
Copy link
Member

kallentu commented May 6, 2024

This is the implementation issue for a potential new language feature being considered: dart-lang/language#3712

  • Complete the feature specification [Wildcard Variables] Feature Specification #55661
  • Add an experiment flag named wildcard-variables
  • Eventually, add an experiment and release version to gate the feature.
  • Then enable by default when ready to release.
@kallentu kallentu added the area-language Dart language related items (some items might be better tracked at github.com/dart-lang/language). label May 6, 2024
@kallentu kallentu self-assigned this May 6, 2024
@lrhn
Copy link
Member

lrhn commented May 7, 2024

Suggestion: Name the experiment flag wildcard-variables, or non-binding-variables. (Probably the former, it's a better name.)

"Wildcards" by itself is little too vague (I can imagine several different features that could use that name, most involving types. (Imagine being allowed to write * for an unconstrainted type in both covariant and contravariant position, so * Function(*) is all unary functions. I'd call that a wildcard type.)

Possibly also use wildcard-variables for the feature itself (github labels, documentaton). If we're going to be referring to it by name for years, it's better to have a name that's unlikely to clash with a later feature name.

@kallentu
Copy link
Member Author

kallentu commented May 7, 2024

cc. @dart-lang/language-team if you have any other suggestions and/or opinions.

Sure, we can name it wildcard-variables. I'll change the issue names and labels for the feature.

@kallentu kallentu changed the title [Wildcards] Experiment Flag [Wildcard Variables] Experiment Flag May 7, 2024
@kallentu kallentu added the feature-wildcard-variables Implementation of the wildcard variables feature label May 7, 2024
copybara-service bot pushed a commit that referenced this issue May 8, 2024
Getting the flag out so we can at least start writing language and co19 tests.

Adds the experiment flag so we can hide future wildcards work until we're ready to ship.

Bug: #55654
Change-Id: I6185360f371bc7c3c7a109b33aeb7df44e1f1a60
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/365545
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Nate Bosch <nbosch@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
@sgrekhov
Copy link
Contributor

sgrekhov commented May 14, 2024

UPD There is no issue described below. I use macos_arm64 but analyzer-asserts-mac configuration uses X64 build which was outdated on my machine. Sorry for the false alarm.

Please note that ERROR: Flag "wildcard-variables" not recognized. occurs if tests with // SharedOptions=--enable-experiment=wildcard-variables run via test.py

Try python3 tools/test.py -n analyzer-asserts-mac co19/LanguageFeatures/Wildcards/binding_A01_t01 to reproduce

Tested on Dart SDK version: 3.5.0-edge.3dfee274cc75ba4686f709e94496cd4d59b13772 (main) (Tue May 14 07:29:53 2024 +0000) on "macos_arm64"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-language Dart language related items (some items might be better tracked at github.com/dart-lang/language). feature-wildcard-variables Implementation of the wildcard variables feature
Projects
None yet
Development

No branches or pull requests

3 participants