You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by er...@apache.org on 2013/11/06 10:03:12 UTC
[1/2] git commit: [flex-falcon] [refs/heads/develop] - Make room for
more class metadata on JS classes: FLEXJS_CLASS_INFO. Changed implementation
of interface info array to match the new wrapping info object.
Updated Branches:
refs/heads/develop 20296ebb1 -> e87761e50
Make room for more class metadata on JS classes: FLEXJS_CLASS_INFO. Changed implementation of interface info array to match the new wrapping info object.
Signed-off-by: Erik de Bruin <er...@ixsoftware.nl>
Project: http://git-wip-us.apache.org/repos/asf/flex-falcon/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-falcon/commit/abc189b9
Tree: http://git-wip-us.apache.org/repos/asf/flex-falcon/tree/abc189b9
Diff: http://git-wip-us.apache.org/repos/asf/flex-falcon/diff/abc189b9
Branch: refs/heads/develop
Commit: abc189b90dcde2d8ab253217926959f064ad7de7
Parents: 20296eb
Author: Erik de Bruin <er...@ixsoftware.nl>
Authored: Wed Nov 6 10:01:09 2013 +0100
Committer: Erik de Bruin <er...@ixsoftware.nl>
Committed: Wed Nov 6 10:01:09 2013 +0100
----------------------------------------------------------------------
.../internal/codegen/js/flexjs/JSFlexJSEmitter.java | 13 +++++++++++--
.../codegen/js/flexjs/JSFlexJSEmitterTokens.java | 3 ++-
2 files changed, 13 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/abc189b9/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/flexjs/JSFlexJSEmitter.java
----------------------------------------------------------------------
diff --git a/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/flexjs/JSFlexJSEmitter.java b/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/flexjs/JSFlexJSEmitter.java
index 932c3c3..3f3ad05 100644
--- a/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/flexjs/JSFlexJSEmitter.java
+++ b/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/flexjs/JSFlexJSEmitter.java
@@ -950,15 +950,21 @@ public class JSFlexJSEmitter extends JSGoogEmitter implements IJSFlexJSEmitter
writeNewline();
writeNewline();
getDoc().begin();
- getDoc().emitConst(null);
+ getDoc().emitPublic(null);
getDoc().end();
+ // a.B.prototype.AFJS_CLASS_INFO = { interfaces: [a.IC, a.ID] };
write(type.getQualifiedName());
write(ASEmitterTokens.MEMBER_ACCESS);
write(JSEmitterTokens.PROTOTYPE);
write(ASEmitterTokens.MEMBER_ACCESS);
- writeToken(JSFlexJSEmitterTokens.AFJS_INTERFACES);
+ writeToken(JSFlexJSEmitterTokens.FLEXJS_CLASS_INFO);
writeToken(ASEmitterTokens.EQUAL);
+ writeToken(ASEmitterTokens.BLOCK_OPEN);
+
+ // interfaces
+ write(JSFlexJSEmitterTokens.INTERFACES);
+ writeToken(ASEmitterTokens.COLON);
write(ASEmitterTokens.SQUARE_OPEN);
int i = 0;
for (IExpressionNode enode : enodes)
@@ -969,6 +975,9 @@ public class JSFlexJSEmitter extends JSGoogEmitter implements IJSFlexJSEmitter
i++;
}
write(ASEmitterTokens.SQUARE_CLOSE);
+
+ write(ASEmitterTokens.SPACE);
+ write(ASEmitterTokens.BLOCK_CLOSE);
writeNewline(ASEmitterTokens.SEMICOLON);
}
}
http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/abc189b9/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/flexjs/JSFlexJSEmitterTokens.java
----------------------------------------------------------------------
diff --git a/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/flexjs/JSFlexJSEmitterTokens.java b/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/flexjs/JSFlexJSEmitterTokens.java
index 0acef43..10ff880 100644
--- a/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/flexjs/JSFlexJSEmitterTokens.java
+++ b/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/flexjs/JSFlexJSEmitterTokens.java
@@ -26,7 +26,8 @@ import org.apache.flex.compiler.codegen.IEmitterTokens;
*/
public enum JSFlexJSEmitterTokens implements IEmitterTokens
{
- AFJS_INTERFACES("AFJS_INTERFACES"),
+ FLEXJS_CLASS_INFO("FLEXJS_CLASS_INFO"),
+ INTERFACES("interfaces"),
LANGUAGE_QNAME("org.apache.flex.utils.Language"),
UNDERSCORE("_"),
;
[2/2] git commit: [flex-falcon] [refs/heads/develop] - Changed tests
to reflect FLEXJS_CLASS_INFO metadata storage.
Posted by er...@apache.org.
Changed tests to reflect FLEXJS_CLASS_INFO metadata storage.
Signed-off-by: Erik de Bruin <er...@ixsoftware.nl>
Project: http://git-wip-us.apache.org/repos/asf/flex-falcon/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-falcon/commit/e87761e5
Tree: http://git-wip-us.apache.org/repos/asf/flex-falcon/tree/e87761e5
Diff: http://git-wip-us.apache.org/repos/asf/flex-falcon/diff/e87761e5
Branch: refs/heads/develop
Commit: e87761e507d40fe9809915f2a156224d65618a01
Parents: abc189b
Author: Erik de Bruin <er...@ixsoftware.nl>
Authored: Wed Nov 6 10:02:07 2013 +0100
Committer: Erik de Bruin <er...@ixsoftware.nl>
Committed: Wed Nov 6 10:02:07 2013 +0100
----------------------------------------------------------------------
compiler.jx.tests/test-files/flexjs/files/MyController_result.js | 4 ++--
.../test-files/flexjs/projects/interfaces/Test_result.js | 4 ++--
.../flexjs/projects/interfaces/interfaces/IA_result.js | 4 ++--
.../flexjs/projects/interfaces/interfaces/IC_result.js | 4 ++--
4 files changed, 8 insertions(+), 8 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/e87761e5/compiler.jx.tests/test-files/flexjs/files/MyController_result.js
----------------------------------------------------------------------
diff --git a/compiler.jx.tests/test-files/flexjs/files/MyController_result.js b/compiler.jx.tests/test-files/flexjs/files/MyController_result.js
index 0598619..0768cde 100644
--- a/compiler.jx.tests/test-files/flexjs/files/MyController_result.js
+++ b/compiler.jx.tests/test-files/flexjs/files/MyController_result.js
@@ -106,7 +106,7 @@ controllers.MyController.prototype.setDocument = function(document, id) {
};
/**
- * @const
+ * @expose
*/
-controllers.MyController.prototype.AFJS_INTERFACES = [org.apache.flex.core.IDocument];
+controllers.MyController.prototype.FLEXJS_CLASS_INFO = { interfaces: [org.apache.flex.core.IDocument] };
http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/e87761e5/compiler.jx.tests/test-files/flexjs/projects/interfaces/Test_result.js
----------------------------------------------------------------------
diff --git a/compiler.jx.tests/test-files/flexjs/projects/interfaces/Test_result.js b/compiler.jx.tests/test-files/flexjs/projects/interfaces/Test_result.js
index e82298a..3f133ab 100644
--- a/compiler.jx.tests/test-files/flexjs/projects/interfaces/Test_result.js
+++ b/compiler.jx.tests/test-files/flexjs/projects/interfaces/Test_result.js
@@ -19,6 +19,6 @@ Test = function() {
goog.inherits(Test, classes.A);
/**
- * @const
+ * @expose
*/
-Test.prototype.AFJS_INTERFACES = [interfaces.IA, interfaces.IE];
+Test.prototype.FLEXJS_CLASS_INFO = { interfaces: [interfaces.IA, interfaces.IE] };
http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/e87761e5/compiler.jx.tests/test-files/flexjs/projects/interfaces/interfaces/IA_result.js
----------------------------------------------------------------------
diff --git a/compiler.jx.tests/test-files/flexjs/projects/interfaces/interfaces/IA_result.js b/compiler.jx.tests/test-files/flexjs/projects/interfaces/interfaces/IA_result.js
index 30cb5cf..b9b5d55 100644
--- a/compiler.jx.tests/test-files/flexjs/projects/interfaces/interfaces/IA_result.js
+++ b/compiler.jx.tests/test-files/flexjs/projects/interfaces/interfaces/IA_result.js
@@ -10,6 +10,6 @@ interfaces.IA = function() {
};
/**
- * @const
+ * @expose
*/
-interfaces.IA.prototype.AFJS_INTERFACES = [interfaces.IC];
+interfaces.IA.prototype.FLEXJS_CLASS_INFO = { interfaces: [interfaces.IC] };
http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/e87761e5/compiler.jx.tests/test-files/flexjs/projects/interfaces/interfaces/IC_result.js
----------------------------------------------------------------------
diff --git a/compiler.jx.tests/test-files/flexjs/projects/interfaces/interfaces/IC_result.js b/compiler.jx.tests/test-files/flexjs/projects/interfaces/interfaces/IC_result.js
index e1ddae6..aba8ce9 100644
--- a/compiler.jx.tests/test-files/flexjs/projects/interfaces/interfaces/IC_result.js
+++ b/compiler.jx.tests/test-files/flexjs/projects/interfaces/interfaces/IC_result.js
@@ -10,6 +10,6 @@ interfaces.IC = function() {
};
/**
- * @const
+ * @expose
*/
-interfaces.IC.prototype.AFJS_INTERFACES = [interfaces.ID];
+interfaces.IC.prototype.FLEXJS_CLASS_INFO = { interfaces: [interfaces.ID] };