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

Side by Side Diff: pkg/analyzer_experimental/lib/src/generated/element.dart

Issue 14205011: Issue 9845. Compare runtime types using ==. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // This code was auto-generated, is not intended to be edited, and is subject to 1 // This code was auto-generated, is not intended to be edited, and is subject to
2 // significant change. Please see the README file for more information. 2 // significant change. Please see the README file for more information.
3 3
4 library engine.element; 4 library engine.element;
5 5
6 import 'dart:collection'; 6 import 'dart:collection';
7 import 'java_core.dart'; 7 import 'java_core.dart';
8 import 'java_engine.dart'; 8 import 'java_engine.dart';
9 import 'source.dart'; 9 import 'source.dart';
10 import 'scanner.dart' show Keyword; 10 import 'scanner.dart' show Keyword;
(...skipping 1682 matching lines...) Expand 10 before | Expand all | Expand 10 after
1693 * An empty array of compilation unit elements. 1693 * An empty array of compilation unit elements.
1694 */ 1694 */
1695 static List<CompilationUnitElement> EMPTY_ARRAY = new List<CompilationUnitElem ent>(0); 1695 static List<CompilationUnitElement> EMPTY_ARRAY = new List<CompilationUnitElem ent>(0);
1696 /** 1696 /**
1697 * Initialize a newly created compilation unit element to have the given name. 1697 * Initialize a newly created compilation unit element to have the given name.
1698 * @param name the name of this element 1698 * @param name the name of this element
1699 */ 1699 */
1700 CompilationUnitElementImpl(String name) : super.con2(name, -1) { 1700 CompilationUnitElementImpl(String name) : super.con2(name, -1) {
1701 } 1701 }
1702 accept(ElementVisitor visitor) => visitor.visitCompilationUnitElement(this); 1702 accept(ElementVisitor visitor) => visitor.visitCompilationUnitElement(this);
1703 bool operator ==(Object object) => object != null && identical(runtimeType, ob ject.runtimeType) && _source == ((object as CompilationUnitElementImpl)).source; 1703 bool operator ==(Object object) => object != null && runtimeType == object.run timeType && _source == ((object as CompilationUnitElementImpl)).source;
1704 List<PropertyAccessorElement> get accessors => _accessors; 1704 List<PropertyAccessorElement> get accessors => _accessors;
1705 ElementImpl getChild(String identifier28) { 1705 ElementImpl getChild(String identifier28) {
1706 for (PropertyAccessorElement accessor in _accessors) { 1706 for (PropertyAccessorElement accessor in _accessors) {
1707 if (((accessor as PropertyAccessorElementImpl)).identifier == identifier28 ) { 1707 if (((accessor as PropertyAccessorElementImpl)).identifier == identifier28 ) {
1708 return accessor as PropertyAccessorElementImpl; 1708 return accessor as PropertyAccessorElementImpl;
1709 } 1709 }
1710 } 1710 }
1711 for (VariableElement variable in _variables) { 1711 for (VariableElement variable in _variables) {
1712 if (((variable as VariableElementImpl)).identifier == identifier28) { 1712 if (((variable as VariableElementImpl)).identifier == identifier28) {
1713 return variable as VariableElementImpl; 1713 return variable as VariableElementImpl;
(...skipping 318 matching lines...) Expand 10 before | Expand all | Expand 10 after
2032 * @param nameOffset the offset of the name of this element in the file that c ontains the 2032 * @param nameOffset the offset of the name of this element in the file that c ontains the
2033 * declaration of this element 2033 * declaration of this element
2034 */ 2034 */
2035 ElementImpl.con2(String name9, int nameOffset2) { 2035 ElementImpl.con2(String name9, int nameOffset2) {
2036 _jtd_constructor_189_impl(name9, nameOffset2); 2036 _jtd_constructor_189_impl(name9, nameOffset2);
2037 } 2037 }
2038 _jtd_constructor_189_impl(String name9, int nameOffset2) { 2038 _jtd_constructor_189_impl(String name9, int nameOffset2) {
2039 this._name = StringUtilities.intern(name9); 2039 this._name = StringUtilities.intern(name9);
2040 this._nameOffset = nameOffset2; 2040 this._nameOffset = nameOffset2;
2041 } 2041 }
2042 bool operator ==(Object object) => object != null && identical(object.runtimeT ype, runtimeType) && ((object as Element)).location == location; 2042 bool operator ==(Object object) => object != null && object.runtimeType == run timeType && ((object as Element)).location == location;
2043 Element getAncestor(Type elementClass) { 2043 Element getAncestor(Type elementClass) {
2044 Element ancestor = _enclosingElement; 2044 Element ancestor = _enclosingElement;
2045 while (ancestor != null && !isInstanceOf(ancestor, elementClass)) { 2045 while (ancestor != null && !isInstanceOf(ancestor, elementClass)) {
2046 ancestor = ancestor.enclosingElement; 2046 ancestor = ancestor.enclosingElement;
2047 } 2047 }
2048 return ancestor as Element; 2048 return ancestor as Element;
2049 } 2049 }
2050 /** 2050 /**
2051 * Return the child of this element that is uniquely identified by the given i dentifier, or{@code null} if there is no such child. 2051 * Return the child of this element that is uniquely identified by the given i dentifier, or{@code null} if there is no such child.
2052 * @param identifier the identifier used to select a child 2052 * @param identifier the identifier used to select a child
(...skipping 805 matching lines...) Expand 10 before | Expand all | Expand 10 after
2858 Source _source; 2858 Source _source;
2859 /** 2859 /**
2860 * Initialize a newly created HTML element to have the given name. 2860 * Initialize a newly created HTML element to have the given name.
2861 * @param context the analysis context in which the HTML file is defined 2861 * @param context the analysis context in which the HTML file is defined
2862 * @param name the name of this element 2862 * @param name the name of this element
2863 */ 2863 */
2864 HtmlElementImpl(AnalysisContext context, String name) : super.con2(name, -1) { 2864 HtmlElementImpl(AnalysisContext context, String name) : super.con2(name, -1) {
2865 this._context = context; 2865 this._context = context;
2866 } 2866 }
2867 accept(ElementVisitor visitor) => visitor.visitHtmlElement(this); 2867 accept(ElementVisitor visitor) => visitor.visitHtmlElement(this);
2868 bool operator ==(Object object) => identical(runtimeType, object.runtimeType) && _source == ((object as CompilationUnitElementImpl)).source; 2868 bool operator ==(Object object) => runtimeType == object.runtimeType && _sourc e == ((object as CompilationUnitElementImpl)).source;
2869 AnalysisContext get context => _context; 2869 AnalysisContext get context => _context;
2870 ElementKind get kind => ElementKind.HTML; 2870 ElementKind get kind => ElementKind.HTML;
2871 List<HtmlScriptElement> get scripts => _scripts; 2871 List<HtmlScriptElement> get scripts => _scripts;
2872 Source get source => _source; 2872 Source get source => _source;
2873 int get hashCode => _source.hashCode; 2873 int get hashCode => _source.hashCode;
2874 /** 2874 /**
2875 * Set the scripts contained in the HTML file to the given scripts. 2875 * Set the scripts contained in the HTML file to the given scripts.
2876 * @param scripts the scripts 2876 * @param scripts the scripts
2877 */ 2877 */
2878 void set scripts(List<HtmlScriptElement> scripts2) { 2878 void set scripts(List<HtmlScriptElement> scripts2) {
(...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after
3086 List<CompilationUnitElement> _parts = CompilationUnitElementImpl.EMPTY_ARRAY; 3086 List<CompilationUnitElement> _parts = CompilationUnitElementImpl.EMPTY_ARRAY;
3087 /** 3087 /**
3088 * Initialize a newly created library element to have the given name. 3088 * Initialize a newly created library element to have the given name.
3089 * @param context the analysis context in which the library is defined 3089 * @param context the analysis context in which the library is defined
3090 * @param name the name of this element 3090 * @param name the name of this element
3091 */ 3091 */
3092 LibraryElementImpl(AnalysisContext context, LibraryIdentifier name) : super.co n1(name) { 3092 LibraryElementImpl(AnalysisContext context, LibraryIdentifier name) : super.co n1(name) {
3093 this._context = context; 3093 this._context = context;
3094 } 3094 }
3095 accept(ElementVisitor visitor) => visitor.visitLibraryElement(this); 3095 accept(ElementVisitor visitor) => visitor.visitLibraryElement(this);
3096 bool operator ==(Object object) => object != null && identical(runtimeType, ob ject.runtimeType) && _definingCompilationUnit == ((object as LibraryElementImpl) ).definingCompilationUnit; 3096 bool operator ==(Object object) => object != null && runtimeType == object.run timeType && _definingCompilationUnit == ((object as LibraryElementImpl)).definin gCompilationUnit;
3097 ElementImpl getChild(String identifier31) { 3097 ElementImpl getChild(String identifier31) {
3098 if (((_definingCompilationUnit as CompilationUnitElementImpl)).identifier == identifier31) { 3098 if (((_definingCompilationUnit as CompilationUnitElementImpl)).identifier == identifier31) {
3099 return _definingCompilationUnit as CompilationUnitElementImpl; 3099 return _definingCompilationUnit as CompilationUnitElementImpl;
3100 } 3100 }
3101 for (CompilationUnitElement part in _parts) { 3101 for (CompilationUnitElement part in _parts) {
3102 if (((part as CompilationUnitElementImpl)).identifier == identifier31) { 3102 if (((part as CompilationUnitElementImpl)).identifier == identifier31) {
3103 return part as CompilationUnitElementImpl; 3103 return part as CompilationUnitElementImpl;
3104 } 3104 }
3105 } 3105 }
3106 return null; 3106 return null;
(...skipping 2535 matching lines...) Expand 10 before | Expand all | Expand 10 after
5642 abstract class TypeVariableType implements Type2 { 5642 abstract class TypeVariableType implements Type2 {
5643 TypeVariableElement get element; 5643 TypeVariableElement get element;
5644 } 5644 }
5645 /** 5645 /**
5646 * The interface {@code VoidType} defines the behavior of the unique object repr esenting the type{@code void}. 5646 * The interface {@code VoidType} defines the behavior of the unique object repr esenting the type{@code void}.
5647 * @coverage dart.engine.type 5647 * @coverage dart.engine.type
5648 */ 5648 */
5649 abstract class VoidType implements Type2 { 5649 abstract class VoidType implements Type2 {
5650 VoidType substitute2(List<Type2> argumentTypes, List<Type2> parameterTypes); 5650 VoidType substitute2(List<Type2> argumentTypes, List<Type2> parameterTypes);
5651 } 5651 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698