| OLD | NEW |
| 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 /// ----------------------------------------------------------------------- | 5 /// ----------------------------------------------------------------------- |
| 6 /// ERROR HANDLING | 6 /// ERROR HANDLING |
| 7 /// ----------------------------------------------------------------------- | 7 /// ----------------------------------------------------------------------- |
| 8 /// | 8 /// |
| 9 /// As a rule of thumb, errors that can be detected statically are handled by | 9 /// As a rule of thumb, errors that can be detected statically are handled by |
| 10 /// the frontend, typically by translating the erroneous code into a 'throw' or | 10 /// the frontend, typically by translating the erroneous code into a 'throw' or |
| (...skipping 1812 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1823 } | 1823 } |
| 1824 } | 1824 } |
| 1825 | 1825 |
| 1826 /// Expression of form `super.foo(x)`. | 1826 /// Expression of form `super.foo(x)`. |
| 1827 /// | 1827 /// |
| 1828 /// The provided arguments might not match the parameters of the target. | 1828 /// The provided arguments might not match the parameters of the target. |
| 1829 class SuperMethodInvocation extends InvocationExpression { | 1829 class SuperMethodInvocation extends InvocationExpression { |
| 1830 Name name; | 1830 Name name; |
| 1831 Arguments arguments; | 1831 Arguments arguments; |
| 1832 | 1832 |
| 1833 Member interfaceTarget; | 1833 Procedure interfaceTarget; |
| 1834 | 1834 |
| 1835 SuperMethodInvocation(this.name, this.arguments, this.interfaceTarget) { | 1835 SuperMethodInvocation(this.name, this.arguments, this.interfaceTarget) { |
| 1836 arguments?.parent = this; | 1836 arguments?.parent = this; |
| 1837 } | 1837 } |
| 1838 | 1838 |
| 1839 DartType getStaticType(TypeEnvironment types) { | 1839 DartType getStaticType(TypeEnvironment types) { |
| 1840 if (interfaceTarget == null) return const DynamicType(); | 1840 if (interfaceTarget == null) return const DynamicType(); |
| 1841 Class superclass = interfaceTarget.enclosingClass; | 1841 Class superclass = interfaceTarget.enclosingClass; |
| 1842 var receiverType = | 1842 var receiverType = |
| 1843 types.hierarchy.getTypeAsInstanceOf(types.thisType, superclass); | 1843 types.hierarchy.getTypeAsInstanceOf(types.thisType, superclass); |
| (...skipping 1822 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3666 } | 3666 } |
| 3667 } | 3667 } |
| 3668 } | 3668 } |
| 3669 | 3669 |
| 3670 class Source { | 3670 class Source { |
| 3671 final List<int> lineStarts; | 3671 final List<int> lineStarts; |
| 3672 final String source; | 3672 final String source; |
| 3673 | 3673 |
| 3674 Source(this.lineStarts, this.source); | 3674 Source(this.lineStarts, this.source); |
| 3675 } | 3675 } |
| OLD | NEW |