Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(19)

Unified Diff: pkg/analysis_server/test/services/completion/optype_test.dart

Issue 1082233003: suggest "this." local fields in constructor param (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: merge Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/analysis_server/test/services/completion/imported_reference_contributor_test.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analysis_server/test/services/completion/optype_test.dart
diff --git a/pkg/analysis_server/test/services/completion/optype_test.dart b/pkg/analysis_server/test/services/completion/optype_test.dart
index ff74539d11a0cb6d1636b313632602254493b98b..3e487c871d88b38a2c900b0d4b91df971b5677eb 100644
--- a/pkg/analysis_server/test/services/completion/optype_test.dart
+++ b/pkg/analysis_server/test/services/completion/optype_test.dart
@@ -1131,6 +1131,42 @@ class C2 {
assertOpType(returnValue: true, voidReturn: true, prefixed: true);
}
+ test_ThisExpression_constructor_param() {
+ // SimpleIdentifier FieldFormalParameter FormalParameterList
+ addTestSource('''
+ class A implements I {
+ A(this.^) {}
+ }''');
+ assertOpType(prefixed: true);
+ }
+
+ test_ThisExpression_constructor_param2() {
+ // SimpleIdentifier FieldFormalParameter FormalParameterList
+ addTestSource('''
+ class A implements I {
+ A(this.f^) {}
+ }''');
+ assertOpType(prefixed: true);
+ }
+
+ test_ThisExpression_constructor_param3() {
+ // SimpleIdentifier FieldFormalParameter FormalParameterList
+ addTestSource('''
+ class A implements I {
+ A(this.^f) {}
+ }''');
+ assertOpType(prefixed: true);
+ }
+
+ test_ThisExpression_constructor_param4() {
+ // FieldFormalParameter FormalParameterList ConstructorDeclaration
+ addTestSource('''
+ class A implements I {
+ A(Str^ this.foo) {}
+ }''');
+ assertOpType(typeNames: true);
+ }
+
test_ThrowExpression() {
// SimpleIdentifier ThrowExpression ExpressionStatement
addTestSource('main() {throw ^;}');
« no previous file with comments | « pkg/analysis_server/test/services/completion/imported_reference_contributor_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698