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

Side by Side Diff: lib/config.dart

Issue 963063003: DDC fixes on DDC (Closed) Base URL: https://github.com/dart-lang/dev_compiler.git@master
Patch Set: Created 5 years, 9 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 | lib/src/codegen/js_codegen.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) 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 /// Configuration of DDC rule set. 5 /// Configuration of DDC rule set.
6 library ddc.config; 6 library ddc.config;
7 7
8 // Options shared by the compiler and runtime. 8 // Options shared by the compiler and runtime.
9 class TypeOptions { 9 class TypeOptions {
10 static const NONNULLABLE_TYPES = const <String>['int', 'double']; 10 static const NONNULLABLE_TYPES = const <String>['int', 'double'];
11 final nonnullableTypes; 11 final List<String> nonnullableTypes;
12 12
13 TypeOptions({this.nonnullableTypes: NONNULLABLE_TYPES}); 13 TypeOptions({this.nonnullableTypes: NONNULLABLE_TYPES});
14 } 14 }
15 15
16 List<String> optionsToList(String option, 16 List<String> optionsToList(String option,
17 {List<String> defaultValue: const <String>[]}) { 17 {List<String> defaultValue: const <String>[]}) {
18 if (option == null) { 18 if (option == null) {
19 return defaultValue; 19 return defaultValue;
20 } else if (option.isEmpty) { 20 } else if (option.isEmpty) {
21 return <String>[]; 21 return <String>[];
22 } else { 22 } else {
23 return option.split(','); 23 return option.split(',');
24 } 24 }
25 } 25 }
OLDNEW
« no previous file with comments | « no previous file | lib/src/codegen/js_codegen.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698