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

Unified Diff: pkg/compiler/lib/src/js_emitter/old_emitter/reflection_data_parser.dart

Issue 963453002: Do not update original descriptor when building new one. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/js_emitter/old_emitter/reflection_data_parser.dart
diff --git a/pkg/compiler/lib/src/js_emitter/old_emitter/reflection_data_parser.dart b/pkg/compiler/lib/src/js_emitter/old_emitter/reflection_data_parser.dart
index 639b5fa6ab1d5ea6703d0fc7977f17e7e9aebc2e..f54481716c77af9933f22f361cb7a9b2838c79e0 100644
--- a/pkg/compiler/lib/src/js_emitter/old_emitter/reflection_data_parser.dart
+++ b/pkg/compiler/lib/src/js_emitter/old_emitter/reflection_data_parser.dart
@@ -82,7 +82,7 @@ jsAst.Expression getReflectionDataParser(OldEmitter oldEmitter,
elem != null &&
elem.constructor === Array &&
property !== "<>") {
- addStubs(newDesc, elem, property, false, descriptor, []);
+ addStubs(newDesc, elem, property, false, []);
} else {
newDesc[previousProperty = property] = elem;
}
@@ -163,8 +163,7 @@ jsAst.Expression getReflectionDataParser(OldEmitter oldEmitter,
#globalFunctions[property] = element;
} else if (element.constructor === Array) {
if (#needsStructuredMemberInfo) {
- addStubs(globalObject, element, property,
- true, descriptor, functions);
+ addStubs(globalObject, element, property, true, functions);
}
} else {
// We will not enter this case if no classes are defined.
@@ -186,8 +185,7 @@ jsAst.Expression getReflectionDataParser(OldEmitter oldEmitter,
* [array].
*/
jsAst.Statement addStubs = js.statement('''
- function addStubs(descriptor, array, name, isStatic,
- originalDescriptor, functions) {
+ function addStubs(descriptor, array, name, isStatic, functions) {
floitsch 2015/02/26 13:02:54 while you are at it... imho descriptor is a reall
herhut 2015/03/09 13:33:58 I will do this in a later CL to avoid loads of mer
var index = $FUNCTION_INDEX, alias = array[index], f;
if (typeof alias == "string") {
f = array[++index];
@@ -195,8 +193,7 @@ jsAst.Expression getReflectionDataParser(OldEmitter oldEmitter,
f = alias;
alias = name;
}
- var funcs = [originalDescriptor[name] = descriptor[name] =
- descriptor[alias] = f];
+ var funcs = [descriptor[name] = descriptor[alias] = f];
f.\$stubName = name;
functions.push(name);
for (; index < array.length; index += 2) {
@@ -205,7 +202,7 @@ jsAst.Expression getReflectionDataParser(OldEmitter oldEmitter,
f.\$stubName = ${readString("array", "index + 2")};
funcs.push(f);
if (f.\$stubName) {
- originalDescriptor[f.\$stubName] = descriptor[f.\$stubName] = f;
+ descriptor[f.\$stubName] = f;
functions.push(f.\$stubName);
}
}
@@ -234,7 +231,7 @@ jsAst.Expression getReflectionDataParser(OldEmitter oldEmitter,
f.\$getterStub = true;
// Used to create an isolate using spawnFunction.
if (isStatic) #globalFunctions[name] = f;
- originalDescriptor[getterStubName] = descriptor[getterStubName] = f;
+ descriptor[getterStubName] = f;
funcs.push(f);
if (getterStubName) functions.push(getterStubName);
f.\$stubName = getterStubName;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698