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

Side by Side Diff: pkg/compiler/lib/src/compiler.dart

Issue 2824423002: Compute NativeBasicData for KernelWorldBuilder (Closed)
Patch Set: Put computeNativeBasicData into KernelAnnotationProcessor. Created 3 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
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 library dart2js.compiler_base; 5 library dart2js.compiler_base;
6 6
7 import 'dart:async' show Future; 7 import 'dart:async' show Future;
8 8
9 import '../compiler_new.dart' as api; 9 import '../compiler_new.dart' as api;
10 import 'closure.dart' as closureMapping show ClosureTask; 10 import 'closure.dart' as closureMapping show ClosureTask;
(...skipping 1898 matching lines...) Expand 10 before | Expand all | Expand 10 after
1909 if (cls == null && required) { 1909 if (cls == null && required) {
1910 throw new SpannableAssertionFailure( 1910 throw new SpannableAssertionFailure(
1911 cls, 1911 cls,
1912 "The library '${library.libraryName}' does not " 1912 "The library '${library.libraryName}' does not "
1913 "contain required class: '$name'."); 1913 "contain required class: '$name'.");
1914 } 1914 }
1915 return cls?.declaration; 1915 return cls?.declaration;
1916 } 1916 }
1917 1917
1918 @override 1918 @override
1919 void forEachClass(LibraryElement library, void f(ClassElement cls)) {
1920 library.implementation.forEachLocalMember((member) {
1921 if (member.isClass) {
1922 f(member);
1923 }
1924 });
1925 }
1926
1927 @override
1919 LibraryElement lookupLibrary(Uri uri, {bool required: false}) { 1928 LibraryElement lookupLibrary(Uri uri, {bool required: false}) {
1920 LibraryElement library = _libraryProvider.lookupLibrary(uri); 1929 LibraryElement library = _libraryProvider.lookupLibrary(uri);
1921 // If the script of the library is synthesized, the library does not exist 1930 // If the script of the library is synthesized, the library does not exist
1922 // and we do not try to load the helpers. 1931 // and we do not try to load the helpers.
1923 // 1932 //
1924 // This could for example happen if dart:async is disabled, then loading it 1933 // This could for example happen if dart:async is disabled, then loading it
1925 // should not try to find the given element. 1934 // should not try to find the given element.
1926 if (library != null && library.isSynthesized) { 1935 if (library != null && library.isSynthesized) {
1927 return null; 1936 return null;
1928 } 1937 }
(...skipping 29 matching lines...) Expand all
1958 ResolutionFunctionType getLocalFunctionType(LocalFunctionElement function) { 1967 ResolutionFunctionType getLocalFunctionType(LocalFunctionElement function) {
1959 return function.type; 1968 return function.type;
1960 } 1969 }
1961 1970
1962 @override 1971 @override
1963 ResolutionDartType getUnaliasedType(ResolutionDartType type) { 1972 ResolutionDartType getUnaliasedType(ResolutionDartType type) {
1964 type.computeUnaliased(_resolution); 1973 type.computeUnaliased(_resolution);
1965 return type.unaliased; 1974 return type.unaliased;
1966 } 1975 }
1967 } 1976 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698