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

Side by Side Diff: pkg/analyzer/lib/dart/element/element.dart

Issue 2336503003: fix #25578, implement @covariant parameter overrides (Closed)
Patch Set: fix comments, format Created 4 years, 3 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 unified diff | Download patch
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/dart/element/element.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 * Defines the element model. The element model describes the semantic (as 6 * Defines the element model. The element model describes the semantic (as
7 * opposed to syntactic) structure of Dart code. The syntactic structure of the 7 * opposed to syntactic) structure of Dart code. The syntactic structure of the
8 * code is modeled by the [AST structure](../ast/ast.dart). 8 * code is modeled by the [AST structure](../ast/ast.dart).
9 * 9 *
10 * The element model consists of two closely related kinds of objects: elements 10 * The element model consists of two closely related kinds of objects: elements
(...skipping 1616 matching lines...) Expand 10 before | Expand all | Expand 10 after
1627 * An empty list of parameter elements. 1627 * An empty list of parameter elements.
1628 */ 1628 */
1629 static const List<ParameterElement> EMPTY_LIST = const <ParameterElement>[]; 1629 static const List<ParameterElement> EMPTY_LIST = const <ParameterElement>[];
1630 1630
1631 /** 1631 /**
1632 * Return the Dart code of the default value, or `null` if no default value. 1632 * Return the Dart code of the default value, or `null` if no default value.
1633 */ 1633 */
1634 String get defaultValueCode; 1634 String get defaultValueCode;
1635 1635
1636 /** 1636 /**
1637 * Return `true` if this parameter is covariant, meaning it is allowed to have
1638 * a narrower type in an override.
1639 */
1640 bool get isCovariant;
1641
1642 /**
1637 * Return `true` if this parameter is an initializing formal parameter. 1643 * Return `true` if this parameter is an initializing formal parameter.
1638 */ 1644 */
1639 bool get isInitializingFormal; 1645 bool get isInitializingFormal;
1640 1646
1641 /** 1647 /**
1642 * Return the kind of this parameter. 1648 * Return the kind of this parameter.
1643 */ 1649 */
1644 ParameterKind get parameterKind; 1650 ParameterKind get parameterKind;
1645 1651
1646 /** 1652 /**
(...skipping 374 matching lines...) Expand 10 before | Expand all | Expand 10 after
2021 DartType get type; 2027 DartType get type;
2022 2028
2023 /** 2029 /**
2024 * Return a representation of the value of this variable, forcing the value 2030 * Return a representation of the value of this variable, forcing the value
2025 * to be computed if it had not previously been computed, or `null` if either 2031 * to be computed if it had not previously been computed, or `null` if either
2026 * this variable was not declared with the 'const' modifier or if the value of 2032 * this variable was not declared with the 'const' modifier or if the value of
2027 * this variable could not be computed because of errors. 2033 * this variable could not be computed because of errors.
2028 */ 2034 */
2029 DartObject computeConstantValue(); 2035 DartObject computeConstantValue();
2030 } 2036 }
OLDNEW
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/dart/element/element.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698