[dart-lang/sdk] 931a3f: [analysis_server] Fix type name for constructors f...

0 views
Skip to first unread message

Danny Tuppeny

unread,
Apr 2, 2026, 4:27:53 PM (yesterday) Apr 2
to com...@dartlang.org
Branch: refs/heads/main
Home: https://github.com/dart-lang/sdk
Commit: 931a3ff671385b0495045935004306dc4a870a63
https://github.com/dart-lang/sdk/commit/931a3ff671385b0495045935004306dc4a870a63
Author: Danny Tuppeny <da...@tuppeny.com>
Date: 2026-04-02 (Thu, 02 Apr 2026)

Changed paths:
M pkg/analysis_server/lib/src/services/completion/dart/candidate_suggestion.dart
M pkg/analysis_server/lib/src/services/completion/dart/declaration_helper.dart
M pkg/analysis_server/test/lsp/completion_dart_test.dart
M pkg/analysis_server/test/services/completion/dart/declaration/local_library_test.dart
M pkg/analysis_server/test/services/completion/dart/declaration/local_reference_test.dart

Log Message:
-----------
[analysis_server] Fix type name for constructors from type aliases in completion

We were adding constructors to completion for type aliases, but not using the type alias in the completion, which mean a lot of duplicates against the target class (see https://github.com/Dart-Code/Dart-Code/issues/6003).

I don't know if this got lost in one of the completion refactors, as there didn't seem to be support in `ConstructorSuggestion` for this, so I've added an `alias` field to it to override the name.

Fixes https://github.com/Dart-Code/Dart-Code/issues/6003

Change-Id: I06c073b1a9cae012c5bdf0fb8a3aa22f8fed728c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/491880
Commit-Queue: Brian Wilkerson <brianwi...@google.com>
Reviewed-by: Brian Wilkerson <brianwi...@google.com>
Reviewed-by: Keerti Parthasarathy <kee...@google.com>



To unsubscribe from these emails, change your notification settings at https://github.com/dart-lang/sdk/settings/notifications
Reply all
Reply to author
Forward
0 new messages