I just ran into another issue.

I’m not sure why dual would have changed this, but I’m now getting an 
(erroneous) error when trying to use Promises:

Incorrect number of arguments.  Expected no more than 0

                        return new Promise(function(resolve:*,reject:*):void{
                               ^

> On Jun 1, 2017, at 10:39 AM, Harbs <harbs.li...@gmail.com> wrote:
> 
> My bad. I accidentally overwrote my copy of BasicJS.swc.
> 
> After fixing some issues, I got my app to run using the latest dual changes.
> 
> All in all, switching to dual went a lot better than I expected.
> 
> Great work, Alex!
> 
> I think the switch to the dual approach was the right one. There’s still 
> probably some rough edges to improve, but it’s definitely usable.
> 
> Thanks,
> Harbs
> 
>> On Jun 1, 2017, at 5:57 AM, Harbs <harbs.li...@gmail.com> wrote:
>> 
>> Another weird issue:
>> 
>>> /Users/harbs/Documents/git/PrintUI/printui-flexjs/PortedPrintUI/src/com/printui/dummy/view/Image.as(12):
>>>  col: 15 interface method imageElement in interface IImage not implemented 
>>> by class Image
>>> 
>>>     public class Image extends BinaryImage
>>>                  ^
>>> 
>>> /Users/harbs/Documents/git/PrintUI/printui-flexjs/PortedPrintUI/src/com/printui/dummy/view/Image.as(12):
>>>  col: 15 interface method applyImageData in interface IImage not 
>>> implemented by class Image
>>> 
>>>     public class Image extends BinaryImage
>>> 
>> 
>> org.apache.flex.html.BinaryImage which in tern subclasses 
>> org.apache.flex.html.Image. org.apache.flex.html.Image implements these two 
>> methods. I figured the compiler might be getting confused by the fact that 
>> Image is named the same as an ancestor class, so I changed the name and I'm 
>> getting the same error in additon to a null pointer error:
>> 
>>>     
>>> /Users/harbs/Documents/git/PrintUI/printui-flexjs/PortedPrintUI/src/com/printui/dummy/view/PUIImage.as(12):
>>>  col: 15 interface method imageElement in interface IImage not implemented 
>>> by class PUIImage
>>> 
>>>     public class PUIImage extends BinaryImage
>>>                  ^
>>> 
>>> /Users/harbs/Documents/git/PrintUI/printui-flexjs/PortedPrintUI/src/com/printui/dummy/view/PUIImage.as(12):
>>>  col: 15 interface method applyImageData in interface IImage not 
>>> implemented by class PUIImage
>>> 
>>>     public class PUIImage extends BinaryImage
>>>                  ^
>>> 
>>> /Users/harbs/Documents/git/PrintUI/printui-flexjs/PortedPrintUI/src/com/printui/view/components/DesignAreaComponents/drawnObjects/ImageObject.as(59):
>>>  col: 3 java.lang.NullPointerException
>>>     at 
>>> org.apache.flex.compiler.internal.projects.FlexProject.isValidTypeConversion(FlexProject.java:2304)
>>>     at 
>>> org.apache.flex.compiler.internal.semantics.MethodBodySemanticChecker.checkImplicitConversion(MethodBodySemanticChecker.java:564)
>>>     at 
>>> org.apache.flex.compiler.internal.semantics.MethodBodySemanticChecker.checkImplicitConversion(MethodBodySemanticChecker.java:374)
>>>     at 
>>> org.apache.flex.compiler.internal.semantics.MethodBodySemanticChecker.checkAssignment(MethodBodySemanticChecker.java:246)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.ABCGeneratingReducer.reduce_assignToNameExpr_to_void_expression(ABCGeneratingReducer.java:2947)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.CmcEmitter.action_237(CmcEmitter.java:4451)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.CmcEmitter.dispatchAction(CmcEmitter.java:8067)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.CmcEmitter.reduceAntecedent(CmcEmitter.java:39127)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.CmcEmitter.dispatchAction(CmcEmitter.java:9362)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.CmcEmitter.reduceAntecedent(CmcEmitter.java:39127)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.CmcEmitter.reduce(CmcEmitter.java:39104)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.CmcEmitter.reduceSubgoals(CmcEmitter.java:39155)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.CmcEmitter.reduceAntecedent(CmcEmitter.java:39126)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.CmcEmitter.reduce(CmcEmitter.java:39104)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.CmcEmitter.reduceSubgoals(CmcEmitter.java:39146)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.CmcEmitter.reduceAntecedent(CmcEmitter.java:39126)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.CmcEmitter.reduce(CmcEmitter.java:39104)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.CmcEmitter.burm(CmcEmitter.java:39406)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.ABCGenerator.generateInstructions(ABCGenerator.java:228)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.ABCGenerator.generateMethodBodyForFunction(ABCGenerator.java:393)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.ABCGenerator.generateMethodBodyForFunction(ABCGenerator.java:347)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.ABCGenerator.generateFunction(ABCGenerator.java:262)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.ClassDirectiveProcessor.finishClassDefinition(ClassDirectiveProcessor.java:639)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.GlobalDirectiveProcessor.declareClass(GlobalDirectiveProcessor.java:430)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.DirectiveProcessor.processNode(DirectiveProcessor.java:206)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.DirectiveProcessor.traverse(DirectiveProcessor.java:188)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.GlobalDirectiveProcessor.declarePackage(GlobalDirectiveProcessor.java:455)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.DirectiveProcessor.processNode(DirectiveProcessor.java:223)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.DirectiveProcessor.traverse(DirectiveProcessor.java:188)
>>>     at 
>>> org.apache.flex.compiler.internal.as.codegen.ABCGenerator.generate(ABCGenerator.java:122)
>>>     at 
>>> org.apache.flex.compiler.internal.units.ASCompilationUnit.handleABCBytesRequest(ASCompilationUnit.java:389)
>>>     at 
>>> org.apache.flex.compiler.internal.units.CompilationUnitBase.processABCBytesRequest(CompilationUnitBase.java:876)
>>>     at 
>>> org.apache.flex.compiler.internal.units.CompilationUnitBase.access$300(CompilationUnitBase.java:109)
>>>     at 
>>> org.apache.flex.compiler.internal.units.CompilationUnitBase$4$1.call(CompilationUnitBase.java:313)
>>>     at 
>>> org.apache.flex.compiler.internal.units.CompilationUnitBase$4$1.call(CompilationUnitBase.java:309)
>>>     at 
>>> org.apache.flex.compiler.internal.units.requests.RequestMaker$1.call(RequestMaker.java:228)
>>>     at 
>>> org.apache.flex.compiler.internal.units.requests.RequestMaker$1.call(RequestMaker.java:222)
>>>     at java.util.concurrent.FutureTask.run(FutureTask.java:266)
>>>     at 
>>> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
>>>     at 
>>> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
>>>     at java.lang.Thread.run(Thread.java:745)
>> 
>> 
>> Any suggestions?
>> 
>>> On Jun 1, 2017, at 12:38 AM, Harbs <harbs.li...@gmail.com> wrote:
>>> 
>>> I just switched to dual and I’m getting lots of errors. These errors seem 
>>> to be exactly what I was afraid of, and I’m not sure how to resolve without 
>>> being restricted by naming of properties and methods.
>>> 
>>> 1. I’m using a mask setter and getter for images it’s now giving override 
>>> errors.
>>> 2. contains() is an incompatible override.
>>> 3. scaleX and scaleY
>>> 4. blendMode
>>> 5. rotation
>>> 6. filters
>>> 7. mouseEnabled
>>> etc….
>>> 
>>> I thought there was supposed to be something built into the compiler to 
>>> hide the flash-specific APIs and allow reuse of them.
>>> 
>>> Am I missing something?
>>> 
>>> Thanks,
>>> Harbs
>> 
> 

Reply via email to