0 Replies Latest reply on Sep 19, 2013 4:13 AM by mihau12345

    [mobile] iOS compilation error for simple application - all listings included

    mihau12345 Level 1

      Hi, i have very simple app for those example
      one view and one basic var with xml

       

      <?xml version="1.0" encoding="utf-8"?>

      <s:View xmlns:fx="http://ns.adobe.com/mxml/2009"

              xmlns:s="library://ns.adobe.com/flex/spark"

              title="HomeView"

              initialize="init(event)">

          <fx:Script>

              <![CDATA[

                  import mx.events.FlexEvent;

       

                  protected function init(event:FlexEvent):void

                  {

       

      var content:XML = new XML('<list>' +
      '<name_elem_dict>sms</name_elem_dict>' +
      '<code_elem_dict>1</code_elem_dict>' +
      '<name>something</name>' +
      '</list>');


      var result:Object = new Object();
          
                 

      trace(content.*::name[0].toString());

      if(content.*::name[0] != undefined)  {
           result._name = content.*::name[0].toString();
      }

      if(content.*::name_elem_dict[0] != undefined)
      {
           result._name_elem_dict = content.*::name_elem_dict[0].toString();
      }

       

                    }

       

              ]]>

          </fx:Script>

      </s:View>


      I've tested it many times and it's really strange - blue content are compiling withouth problems,
      but red section with content.*::name[0] couse strange error - both lines: if(), and assigning to var (testet separetly).

       

      REALLY STRANGE: trace(content.*::name[0].toString()); this one doesn't couse any compilation errors

       

      ERROR LISTING:


      Error occurred while packaging the application:

       

      AOT Compilation has failed while optimizing function views::XmlTestsHomeView.init

       

      Exception in thread "main" java.lang.NullPointerException

          at adobe.abc.Nsset.match(Nsset.java:263)

          at adobe.abc.Name.match(Name.java:555)

          at adobe.abc.Symtab.getEntry(Symtab.java:37)

          at adobe.abc.Symtab.get(Symtab.java:55)

          at adobe.abc.Type.find(Type.java:205)

          at adobe.abc.Type.findGet(Type.java:611)

          at adobe.abc.GlobalOptimizer.sccp_eval(GlobalOptimizer.java:6532)

          at adobe.abc.GlobalOptimizer.sccp_analyze(GlobalOptimizer.java:6019)

          at adobe.abc.GlobalOptimizer.sccp(GlobalOptimizer.java:4733)

          at adobe.abc.GlobalOptimizer.optimize(GlobalOptimizer.java:3615)

          at adobe.abc.GlobalOptimizer.optimize(GlobalOptimizer.java:2309)

          at adobe.abc.LLVMEmitter.optimizeABCs(LLVMEmitter.java:534)

          at adobe.abc.LLVMEmitter.generateBitcode(LLVMEmitter.java:343)

         at com.adobe.air.ipa.AOTCompiler.convertAbcToLlvmBitcodeImpl(AOTCompiler.java:611)

          at com.adobe.air.ipa.BitcodeGenerator.main(BitcodeGenerator.java:104)

      Compilation failed while executing : ADT

       

       

       

      My Flex Builder compilation info:
      FB 4.7

      Flex 4.9.0 FP11.1 en_US
      Adobe AIR 3.8