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

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

Issue 1170673002: Begin to compute constant expressions in resolution. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Fix BinaryConstantExpression.getKnownType Created 5 years, 6 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 | « pkg/compiler/lib/src/constants/values.dart ('k') | pkg/compiler/lib/src/deferred_load.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 library dart2js.type_system; 5 library dart2js.type_system;
6 6
7 import 'dart_types.dart'; 7 import 'dart_types.dart';
8 import 'elements/elements.dart' show ClassElement; 8 import 'elements/elements.dart' show ClassElement;
9 9
10 /// The core types in Dart. 10 /// The core types in Dart.
11 abstract class CoreTypes { 11 abstract class CoreTypes {
12 /// The `Object` type defined in 'dart:core'. 12 /// The `Object` type defined in 'dart:core'.
13 InterfaceType get objectType; 13 InterfaceType get objectType;
14 14
15 /// The `bool` type defined in 'dart:core'. 15 /// The `bool` type defined in 'dart:core'.
16 InterfaceType get boolType; 16 InterfaceType get boolType;
17 17
18 /// The `bool` type defined in 'dart:core'. 18 /// The `bool` type defined in 'dart:core'.
19 InterfaceType get numType; 19 InterfaceType get numType;
20 20
21 /// The `int` type defined in 'dart:core'. 21 /// The `int` type defined in 'dart:core'.
22 InterfaceType get intType; 22 InterfaceType get intType;
23 23
24 /// The `double` type defined in 'dart:core'. 24 /// The `double` type defined in 'dart:core'.
25 InterfaceType get doubleType; 25 InterfaceType get doubleType;
26 26
27 /// The `String` type defined in 'dart:core'. 27 /// The `String` type defined in 'dart:core'.
28 InterfaceType get stringType; 28 InterfaceType get stringType;
29 29
30 /// The `Symbol` type defined in 'dart:core'.
31 InterfaceType get symbolType;
32
30 /// The `Function` type defined in 'dart:core'. 33 /// The `Function` type defined in 'dart:core'.
31 InterfaceType get functionType; 34 InterfaceType get functionType;
32 35
33 /// The `Null` type defined in 'dart:core'. 36 /// The `Null` type defined in 'dart:core'.
34 InterfaceType get nullType; 37 InterfaceType get nullType;
35 38
36 /// The `Type` type defined in 'dart:core'. 39 /// The `Type` type defined in 'dart:core'.
37 InterfaceType get typeType; 40 InterfaceType get typeType;
38 41
39 /// Returns an instance of the `List` type defined in 'dart:core' with 42 /// Returns an instance of the `List` type defined in 'dart:core' with
40 /// [elementType] as its type argument. 43 /// [elementType] as its type argument.
41 InterfaceType listType([DartType elementType = const DynamicType()]); 44 ///
45 /// If no type argument is provided, the canonical raw type is returned.
46 InterfaceType listType([DartType elementType]);
42 47
43 /// Returns an instance of the `Map` type defined in 'dart:core' with 48 /// Returns an instance of the `Map` type defined in 'dart:core' with
44 /// [keyType] and [valueType] as its type arguments. 49 /// [keyType] and [valueType] as its type arguments.
45 InterfaceType mapType([DartType keyType = const DynamicType(), 50 ///
46 DartType valueType = const DynamicType()]); 51 /// If no type arguments are provided, the canonical raw type is returned.
52 InterfaceType mapType([DartType keyType, DartType valueType]);
47 53
48 /// Returns an instance of the `Iterable` type defined in 'dart:core' with 54 /// Returns an instance of the `Iterable` type defined in 'dart:core' with
49 /// [elementType] as its type argument. 55 /// [elementType] as its type argument.
50 InterfaceType iterableType([DartType elementType = const DynamicType()]); 56 ///
57 /// If no type argument is provided, the canonical raw type is returned.
58 InterfaceType iterableType([DartType elementType]);
51 59
52 /// The `Future` class declaration. 60 /// The `Future` class declaration.
53 ClassElement get futureClass; 61 ClassElement get futureClass;
54 62
55 /// Returns an instance of the `Future` type defined in 'dart:async' with 63 /// Returns an instance of the `Future` type defined in 'dart:async' with
56 /// [elementType] as its type argument. 64 /// [elementType] as its type argument.
57 InterfaceType futureType([DartType elementType = const DynamicType()]); 65 ///
66 /// If no type argument is provided, the canonical raw type is returned.
67 InterfaceType futureType([DartType elementType]);
58 68
59 /// Returns an instance of the `Stream` type defined in 'dart:async' with 69 /// Returns an instance of the `Stream` type defined in 'dart:async' with
60 /// [elementType] as its type argument. 70 /// [elementType] as its type argument.
61 InterfaceType streamType([DartType elementType = const DynamicType()]); 71 ///
72 /// If no type argument is provided, the canonical raw type is returned.
73 InterfaceType streamType([DartType elementType]);
62 } 74 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/constants/values.dart ('k') | pkg/compiler/lib/src/deferred_load.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698