Skip to content

[Wildcard Variables] Resolution of wildcard import directives #56245

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

Closed
Tracked by #55680
pq opened this issue Jul 15, 2024 · 0 comments
Closed
Tracked by #55680

[Wildcard Variables] Resolution of wildcard import directives #56245

pq opened this issue Jul 15, 2024 · 0 comments
Assignees
Labels
feature-wildcard-variables Implementation of the wildcard variables feature legacy-area-analyzer Use area-devexp instead. P2 A bug or feature request we're likely to work on type-enhancement A request for a change that isn't a bug

Comments

@pq
Copy link
Member

pq commented Jul 15, 2024

As per dart-lang/language#3799, import prefixes named _ are non-binding but will provide access to the non-private extensions in that library.

// a.dart
extension ExtendedString on String {
  bool get isBlank => trim().isEmpty;
}
// b.dart
import 'a.dart' as _; // OK.

main() {
  print(''.isBlank); // Prints `true`.
}

See: https://github.com/dart-lang/language/blob/main/working/wildcards/feature-specification.md#imports

@pq pq changed the title Resolution of directives [Wildcard Variables] Resolution of wildcard import directives Jul 15, 2024
@pq pq self-assigned this Jul 15, 2024
@dart-github-bot dart-github-bot added legacy-area-front-end Legacy: Use area-dart-model instead. triage-automation See https://github.com/dart-lang/ecosystem/tree/main/pkgs/sdk_triage_bot. type-enhancement A request for a change that isn't a bug labels Jul 15, 2024
@dart-lang dart-lang deleted a comment from dart-github-bot Jul 15, 2024
@pq pq added legacy-area-analyzer Use area-devexp instead. feature-wildcard-variables Implementation of the wildcard variables feature P2 A bug or feature request we're likely to work on and removed legacy-area-front-end Legacy: Use area-dart-model instead. triage-automation See https://github.com/dart-lang/ecosystem/tree/main/pkgs/sdk_triage_bot. labels Jul 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-wildcard-variables Implementation of the wildcard variables feature legacy-area-analyzer Use area-devexp instead. P2 A bug or feature request we're likely to work on type-enhancement A request for a change that isn't a bug
Projects
None yet
Development

No branches or pull requests

2 participants