| OLD | NEW |
| 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.new_js_emitter.model; | 5 library dart2js.new_js_emitter.model; |
| 6 | 6 |
| 7 import '../js/js.dart' as js show Expression, Statement, Name, Literal, | 7 import '../js/js.dart' as js show Expression, Statement, Name, Literal, |
| 8 TokenFinalizer; | 8 TokenFinalizer; |
| 9 import '../constants/values.dart' show ConstantValue; | 9 import '../constants/values.dart' show ConstantValue; |
| 10 | 10 |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 77 } | 77 } |
| 78 | 78 |
| 79 /** | 79 /** |
| 80 * This class represents a JavaScript object that contains static state, like | 80 * This class represents a JavaScript object that contains static state, like |
| 81 * classes or functions. | 81 * classes or functions. |
| 82 */ | 82 */ |
| 83 class Holder { | 83 class Holder { |
| 84 final String name; | 84 final String name; |
| 85 final int index; | 85 final int index; |
| 86 final bool isStaticStateHolder; | 86 final bool isStaticStateHolder; |
| 87 final bool isConstantsHolder; |
| 87 | 88 |
| 88 Holder(this.name, this.index, {this.isStaticStateHolder: false}); | 89 Holder(this.name, this.index, |
| 90 {this.isStaticStateHolder: false, this.isConstantsHolder: false}); |
| 89 } | 91 } |
| 90 | 92 |
| 91 /** | 93 /** |
| 92 * This class represents one output file. | 94 * This class represents one output file. |
| 93 * | 95 * |
| 94 * If no library is deferred, there is only one [Fragment] of type | 96 * If no library is deferred, there is only one [Fragment] of type |
| 95 * [MainFragment]. | 97 * [MainFragment]. |
| 96 */ | 98 */ |
| 97 abstract class Fragment { | 99 abstract class Fragment { |
| 98 /// The outputUnit should only be used during the transition to the new model. | 100 /// The outputUnit should only be used during the transition to the new model. |
| (...skipping 394 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 493 requiredParameterCount: requiredParameterCount, | 495 requiredParameterCount: requiredParameterCount, |
| 494 optionalParameterDefaultValues: optionalParameterDefaultValues, | 496 optionalParameterDefaultValues: optionalParameterDefaultValues, |
| 495 functionType: functionType); | 497 functionType: functionType); |
| 496 } | 498 } |
| 497 | 499 |
| 498 class StaticStubMethod extends StubMethod implements StaticMethod { | 500 class StaticStubMethod extends StubMethod implements StaticMethod { |
| 499 Holder holder; | 501 Holder holder; |
| 500 StaticStubMethod(js.Name name, this.holder, js.Expression code) | 502 StaticStubMethod(js.Name name, this.holder, js.Expression code) |
| 501 : super(name, code); | 503 : super(name, code); |
| 502 } | 504 } |
| OLD | NEW |