temperlang / temper

3 stars 0 forks source link

No be-java overloads for methods in classes #98

Closed tjpalmer closed 8 months ago

tjpalmer commented 8 months ago

We don't get linear overload for the optional param here:

class A { let hi(a: Int, b: Int = 0): Int { a + b } }

Like we do for this:

let hi(a: Int, b: Int = 0): Int { a + b }
    public static int hi(int a__2, @Nullable Integer b__3) {
        if (b__3 == null) {
            b__3 = 0;
        }
        return a__2 + b__3;
    }
    public static int hi(int a__2) {
        return hi(a__2, null);
    }

So calls to the method version without the optional arg cause javac errors.