Chromium Code Reviews| Index: pkg/kernel/lib/ast.dart |
| diff --git a/pkg/kernel/lib/ast.dart b/pkg/kernel/lib/ast.dart |
| index da42f5ebbffc092d69fd49aa9dc5bae9d12da5fe..59fc9ed2f2fff1a647f75806082584d2436d19fa 100644 |
| --- a/pkg/kernel/lib/ast.dart |
| +++ b/pkg/kernel/lib/ast.dart |
| @@ -4237,7 +4237,7 @@ class Supertype extends Node { |
| /// A way to bundle up all the libraries in a program. |
| class Program extends TreeNode { |
| - final CanonicalName root = new CanonicalName.root(); |
| + final CanonicalName root; |
| final List<Library> libraries; |
| @@ -4249,8 +4249,12 @@ class Program extends TreeNode { |
| /// Reference to the main method in one of the libraries. |
| Reference mainMethodName; |
| - Program([List<Library> libraries, Map<String, Source> uriToSource]) |
| - : libraries = libraries ?? <Library>[], |
| + Program( |
| + {CanonicalName nameRoot, |
|
Siggi Cherem (dart-lang)
2017/05/12 16:27:57
just a thought - Kevin if you prefer a different A
|
| + List<Library> libraries, |
| + Map<String, Source> uriToSource}) |
| + : root = nameRoot ?? new CanonicalName.root(), |
| + libraries = libraries ?? <Library>[], |
| uriToSource = uriToSource ?? <String, Source>{} { |
| setParents(this.libraries, this); |
| } |