| OLD | NEW |
| 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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 test.src.serialization.elements_test; | 5 library test.src.serialization.elements_test; |
| 6 | 6 |
| 7 import 'package:analyzer/dart/ast/ast.dart'; | 7 import 'package:analyzer/dart/ast/ast.dart'; |
| 8 import 'package:analyzer/dart/ast/standard_resolution_map.dart'; | 8 import 'package:analyzer/dart/ast/standard_resolution_map.dart'; |
| 9 import 'package:analyzer/dart/constant/value.dart'; | 9 import 'package:analyzer/dart/constant/value.dart'; |
| 10 import 'package:analyzer/dart/element/element.dart'; | 10 import 'package:analyzer/dart/element/element.dart'; |
| (...skipping 2344 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2355 | 2355 |
| 2356 test_const_topLevel_prefix() { | 2356 test_const_topLevel_prefix() { |
| 2357 checkLibrary(r''' | 2357 checkLibrary(r''' |
| 2358 const vNotEqual = 1 != 2; | 2358 const vNotEqual = 1 != 2; |
| 2359 const vNot = !true; | 2359 const vNot = !true; |
| 2360 const vNegate = -1; | 2360 const vNegate = -1; |
| 2361 const vComplement = ~1; | 2361 const vComplement = ~1; |
| 2362 '''); | 2362 '''); |
| 2363 } | 2363 } |
| 2364 | 2364 |
| 2365 test_const_topLevel_this() { |
| 2366 checkLibrary(r''' |
| 2367 const vThis = this; |
| 2368 '''); |
| 2369 } |
| 2370 |
| 2365 test_const_topLevel_typedList() { | 2371 test_const_topLevel_typedList() { |
| 2366 checkLibrary(r''' | 2372 checkLibrary(r''' |
| 2367 const vNull = const <Null>[]; | 2373 const vNull = const <Null>[]; |
| 2368 const vDynamic = const <dynamic>[1, 2, 3]; | 2374 const vDynamic = const <dynamic>[1, 2, 3]; |
| 2369 const vInterfaceNoTypeParameters = const <int>[1, 2, 3]; | 2375 const vInterfaceNoTypeParameters = const <int>[1, 2, 3]; |
| 2370 const vInterfaceNoTypeArguments = const <List>[]; | 2376 const vInterfaceNoTypeArguments = const <List>[]; |
| 2371 const vInterfaceWithTypeArguments = const <List<String>>[]; | 2377 const vInterfaceWithTypeArguments = const <List<String>>[]; |
| 2372 const vInterfaceWithTypeArguments2 = const <Map<int, List<String>>>[]; | 2378 const vInterfaceWithTypeArguments2 = const <Map<int, List<String>>>[]; |
| 2373 '''); | 2379 '''); |
| 2374 } | 2380 } |
| (...skipping 2642 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5017 fail('Unexpectedly tried to get unlinked summary for $uri'); | 5023 fail('Unexpectedly tried to get unlinked summary for $uri'); |
| 5018 } | 5024 } |
| 5019 return serializedUnit; | 5025 return serializedUnit; |
| 5020 } | 5026 } |
| 5021 | 5027 |
| 5022 @override | 5028 @override |
| 5023 bool hasLibrarySummary(String uri) { | 5029 bool hasLibrarySummary(String uri) { |
| 5024 return true; | 5030 return true; |
| 5025 } | 5031 } |
| 5026 } | 5032 } |
| OLD | NEW |