vipcxj / jasync

make async-await code style available in java just like csharp and es6
Apache License 2.0
129 stars 14 forks source link

Compilation error of for loop #15

Closed knuclechan closed 2 years ago

knuclechan commented 2 years ago

Unable to handle an empty for loop

Java Code

@Async
private JPromise<Boolean> method1(){
    for(;;){
        // do something
    }
    .....
}

Build Error

[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR : 
[INFO] -------------------------------------------------------------
[ERROR] SomeFile.java:[692] reference to doFor is ambiguous
  both method doFor(io.github.vipcxj.jasync.spec.functional.VoidPromiseSupplier,io.github.vipcxj.jasync.spec.functional.BooleanSupplier,io.github.vipcxj.jasync.spec.functional.VoidPromiseSupplier,io.github.vipcxj.jasync.spec.functional.VoidPromiseSupplier,java.lang.String) in io.github.vipcxj.jasync.spec.JAsync and method doFor(io.github.vipcxj.jasync.spec.functional.VoidPromiseSupplier,io.github.vipcxj.jasync.spec.functional.PromiseSupplier<java.lang.Boolean>,io.github.vipcxj.jasync.spec.functional.VoidPromiseSupplier,io.github.vipcxj.jasync.spec.functional.VoidPromiseSupplier,java.lang.String) in io.github.vipcxj.jasync.spec.JAsync match
vipcxj commented 2 years ago

fixed in 0.1.13,Please notice, not 1.0.13. The version 1.X.X is a complete new version, change a lot, completely rewrite.

knuclechan commented 2 years ago

Thanks for the fix!