Missing Comment
in childEntries
for some AnnotatedNode
s
#60423
Labels
area-dart-model
For issues related to conformance to the language spec in the parser, compilers or the CLI analyzer.
Some time ago, I was working on #59724 and noticed something weird about
extension
s andtypedef
s not triggering comments suggestions. Today I found out what was actually wrong.Although https://dart-review.googlesource.com/c/sdk/+/411380 makes some suggestions show up, it doesn't work well with
PrefixedIdentifier
s. The problem is that even though both areAnnotatedNode
s, they never add the correspondingComment
on thechildEntries
.See:
Variable:
Typedef:
This makes some completions work weirdly, see on classes:
On typedefs:
This is a problem because at
DartCompletionManager.computeCandidateSuggestions
we callCompilationUnitImpl.select
, which usesAstNodeExtension.nodeCovering
internally for identifying the node.We should probably think of a smart test to guarantee that any new
AnnotatedNode
also containsComment
on thechildEntries
.CC @bwilkerson
The text was updated successfully, but these errors were encountered: