You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Like named constructor, add constructor modifier for unnamed constructor #4495
[Screenshots Attached Below]
I want to apply distinct color to all types of constructors i.e. named or unnamed so that I can quickly spot them wherever they are declared or used. Currently as named constructor has constructor modifier so I have used the following coloring customization:
@shujaatak just to set expectations, this change will ship in the Dart SDK because that's where the semantic tokens are produced. For small changes like this one, I tend to include them in the release notes for the month in which they're done under a note of ("these changes require an SDK update") so that users of the beta/master branches are aware of them (and can test them).
This means it might be longer before the fix will be available in stable SDKs.
Activity
DanTup commentedon Apr 17, 2023
This seems like a bug. In constructor invocations the class names already have this modifier, so the current behaviour is not consistent:
For consistency,
Ain both constructor declarations should have the modifier.I think we might also be missing
declarationmodifiers on constructors, I'll verify that and file an issue if so.shujaatak commentedon Apr 17, 2023
@DanTup You never disappoint 🥇
Thank you for adding this to v3.64.0 milestone!
DanTup commentedon Apr 17, 2023
@shujaatak just to set expectations, this change will ship in the Dart SDK because that's where the semantic tokens are produced. For small changes like this one, I tend to include them in the release notes for the month in which they're done under a note of ("these changes require an SDK update") so that users of the beta/master branches are aware of them (and can test them).
This means it might be longer before the fix will be available in stable SDKs.
shujaatak commentedon Apr 17, 2023
The wait will be worth it!
Thank you @DanTup
[analysis_server] Add missing "constructor" semantic token modifiers …
DanTup commentedon Apr 24, 2023
Fixed by dart-lang/sdk@3069c4f. This change ships in a future SDK update (and not a Dart-Code update).