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 2014/09/16 16:02:00 UTC

[08/11] git commit: [flex-falcon] [refs/heads/develop] - Add null check

Add null check

Prevents exception from being thrown when running full SDK through FalconJX. Check with compiler/SDK guru's about root cause for exception.

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/128904f6
Tree: http://git-wip-us.apache.org/repos/asf/flex-falcon/tree/128904f6
Diff: http://git-wip-us.apache.org/repos/asf/flex-falcon/diff/128904f6

Branch: refs/heads/develop
Commit: 128904f6526ce44c6e81637f5a57905864f44b97
Parents: 55e000f
Author: Erik de Bruin <er...@ixsoftware.nl>
Authored: Tue Sep 16 14:06:18 2014 +0200
Committer: Erik de Bruin <er...@ixsoftware.nl>
Committed: Tue Sep 16 14:06:18 2014 +0200

----------------------------------------------------------------------
 .../compiler/internal/codegen/js/flexjs/JSFlexJSEmitter.java     | 4 ++++
 1 file changed, 4 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/128904f6/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 e31727c..d8b18ae 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
@@ -757,6 +757,10 @@ public class JSFlexJSEmitter extends JSGoogEmitter implements IJSFlexJSEmitter
                 IClassNode cnode = (IClassNode) node
                         .getAncestorOfType(IClassNode.class);
 
+                // ToDo (erikdebruin): add VF2JS conditional -> only use check during full SDK compilation
+                if (cnode == null)
+                    return;
+                
                 write(cnode.getQualifiedName());
                 write(ASEmitterTokens.MEMBER_ACCESS);
                 write(JSGoogEmitterTokens.GOOG_BASE);