[DAS] Fixes completion for dot-shorthand in FutureOr<T> and for switches
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Feel free to replace the reviewers, just a suggestion.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
if (contextType != null && (contextType.isDartAsyncFutureOr)) {Nit: Remove the extra parens
return (contextType as InterfaceType).typeArguments.firstOrNull;Could we use the if to promote the `contextType` to an `InterfaceType`? I think it would just replace the null check anyways. Just so we don't have to cast.
Future<void> test_enum_functionExpression_futureOr() async {Can you also make some tests for classes and extension types? Just to make extra sure that they work too.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
lgtm, once Kallen's comments are addressed.
Kallen: do we want to try to get this cherry picked? It might have a significant impact on the usability of the feature.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
lgtm, once Kallen's comments are addressed.
Kallen: do we want to try to get this cherry picked? It might have a significant impact on the usability of the feature.
Yep, definitely. Any fixes with completion, I want to make sure we get in before the release. I'll work on making that CP once this is submitted (and I fix the other case too
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Auto-Submit | +1 |
if (contextType != null && (contextType.isDartAsyncFutureOr)) {Nit: Remove the extra parens
Done
return (contextType as InterfaceType).typeArguments.firstOrNull;Could we use the if to promote the `contextType` to an `InterfaceType`? I think it would just replace the null check anyways. Just so we don't have to cast.
Great idea! I'd just copied from above.
Future<void> test_enum_functionExpression_futureOr() async {Can you also make some tests for classes and extension types? Just to make extra sure that they work too.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
Future<void> test_enum_functionExpression_futureOr() async {Felipe MorschelCan you also make some tests for classes and extension types? Just to make extra sure that they work too.
Are these enough? Or do you want something more?
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
[DAS] Fixes completion for dot-shorthand in FutureOr<T> and for switches
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |