Skip to main content
Participant
June 21, 2013
Question

FB4.7, iOS compilation fail on "standard" packing method only (fast and AIR simulator works fine)

  • June 21, 2013
  • 0 replies
  • 395 views

Sharing with the community with a bug and solution.

I think this is a compiler bug, but not sure.

AIR-sdk: v.3.4.

Error:

Error occurred while packaging the application:


Exception in thread "main" java.lang.Error: Unable to find named traits: starling.display::Sprite$
    at adobe.abc.Domain.resolveTypeName(Domain.java:232)
    at adobe.abc.Domain.resolveTypeName(Domain.java:149)
    at adobe.abc.GlobalOptimizer.sccp_eval(GlobalOptimizer.java:6703)
    at adobe.abc.GlobalOptimizer$SccpContext.commit(GlobalOptimizer.java:4375)
    at adobe.abc.GlobalOptimizer.sccp_modify(GlobalOptimizer.java:5847)
    at adobe.abc.GlobalOptimizer.sccp_modify(GlobalOptimizer.java:4708)
    at adobe.abc.GlobalOptimizer.sccp(GlobalOptimizer.java:4680)
    at adobe.abc.GlobalOptimizer.optimize(GlobalOptimizer.java:3546)
    at adobe.abc.GlobalOptimizer.optimize(GlobalOptimizer.java:2247)
    at adobe.abc.LLVMEmitter.optimizeABCs(LLVMEmitter.java:532)
    at adobe.abc.LLVMEmitter.generateBitcode(LLVMEmitter.java:341)
    at com.adobe.air.ipa.AOTCompiler.convertAbcToLlvmBitcodeImpl(AOTCompiler.java:533)
    at com.adobe.air.ipa.BitcodeGenerator.main(BitcodeGenerator.java:80)
Compilation failed while executing : ADT

Code that is causing the issue:

var str:String = "123";

var c;

if(str == "123")

{

     c = Sprite;

}

------------------

the same error comes out if introducing changes to the upper code:

- if(str == "1")

Code fixed:

it does compile if any of the following changes are introduced:

- if(true)

- if(false)

- <without the "if" statement>

- var c:Class;

So the problem here is that "var c" has no type declaration of "Class". I guess it might be just "Class" and no errors might occure with any other types.

This topic has been closed for replies.