| library; |
| // |
| // Problems in library: |
| // |
| // pkg/front_end/testcases/regress/invalid_this_reference_08.dart:7:7: Error: Extensions can't declare instance fields |
| // Try removing the field declaration or making it a static field |
| // var foo = this(); |
| // ^^^ |
| // |
| // pkg/front_end/testcases/regress/invalid_this_reference_08.dart:7:13: Error: Expected identifier, but got 'this'. |
| // var foo = this(); |
| // ^^^^ |
| // |
| import self as self; |
| |
| extension Foo on dynamic { |
| get foo = self::Foo|get#foo; |
| set foo = self::Foo|set#foo; |
| method bar = self::Foo|bar; |
| method tearoff bar = self::Foo|get#bar; |
| } |
| static abstract extension-member method Foo|get#foo(lowered dynamic #this) → invalid-type; |
| static abstract extension-member method Foo|set#foo(lowered dynamic #this, synthesized invalid-type #externalFieldValue) → void; |
| static extension-member method Foo|bar(lowered final dynamic #this) → dynamic |
| ; |
| static extension-member method Foo|get#bar(lowered final dynamic #this) → () → dynamic |
| return () → dynamic => self::Foo|bar(#this); |