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

Unified Diff: sdk/lib/_internal/compiler/implementation/js_emitter/container_builder.dart

Issue 179583002: Revert "Emit named parameter information in declaration order." (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | sdk/lib/_internal/compiler/implementation/js_emitter/metadata_emitter.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/_internal/compiler/implementation/js_emitter/container_builder.dart
diff --git a/sdk/lib/_internal/compiler/implementation/js_emitter/container_builder.dart b/sdk/lib/_internal/compiler/implementation/js_emitter/container_builder.dart
index dc4e201c614d90be82ba730167664d698a64c8ec..1caa29fa3e04f6e6e009952b2396eb68bf92e634 100644
--- a/sdk/lib/_internal/compiler/implementation/js_emitter/container_builder.dart
+++ b/sdk/lib/_internal/compiler/implementation/js_emitter/container_builder.dart
@@ -425,8 +425,18 @@ class ContainerBuilder extends CodeEmitterHelper {
if (member.isInstanceMember()) {
Set invokedSelectors =
compiler.codegenWorld.invokedNames[member.name];
+ //if (invokedSelectors != null && invokedSelectors.contains(selector)) {
expressions.add(js.string(namer.invocationName(selector)));
+ //} else {
+ // // Don't add a stub for calling this as a regular instance method,
+ // // we only need the "call" stub for implicit closures of this
+ // // method.
+ // expressions.add("null");
+ //}
} else {
+ // Static methods don't need "named" stubs as the default arguments
+ // are inlined at call sites. But static methods might need "call"
+ // stubs for implicit closures.
expressions.add("null");
// TOOD(ahe): Since we know when reading static data versus instance
// data, we can eliminate this element.
@@ -474,7 +484,7 @@ class ContainerBuilder extends CodeEmitterHelper {
..addAll(task.metadataEmitter.reifyDefaultArguments(member));
if (canBeReflected || canBeApplied) {
- parameters.forEachParameter((Element parameter) {
+ parameters.orderedForEachParameter((Element parameter) {
expressions.add(task.metadataEmitter.reifyName(parameter.name));
List<MetadataAnnotation> annotations = parameter.metadata.toList();
Iterable<int> metadataIndices = annotations.map((MetadataAnnotation a) {
« no previous file with comments | « no previous file | sdk/lib/_internal/compiler/implementation/js_emitter/metadata_emitter.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698