elect
09/26/2022, 1:08 PMtoRadians and toDegrees. Both are present in java.lang.Math but for MP it's a problemKlitos Kyriacou
09/26/2022, 1:13 PMtoRadians and toDegrees would work very nicely with value classes, but then realised that these require @JvmInline so are not usable with multiplatform 🤦♂️ephemient
09/26/2022, 1:32 PMKlitos Kyriacou
09/26/2022, 1:33 PMilya.gorbunov
09/26/2022, 2:03 PMasin(...) (arc sine) function, if there are several types for angular units?Klitos Kyriacou
09/26/2022, 2:16 PMval rightAngle = 90.deg // property deg is defined on Double (or Number)
val y: Double = sin(rightAngle.toRadians()) // sin is only defined for radians
val theta: Radians = asin(y) // asin(Double) returns Radians
val theta2 = theta.toDegrees() // toDegrees() is defined on Radiansephemient
09/27/2022, 12:50 AMKlitos Kyriacou
09/27/2022, 8:21 AMMichael de Kaste
09/28/2022, 9:04 AMMichael de Kaste
09/28/2022, 9:07 AMoperator fun Angle.plus(rotation: Rotation): Angle etc.Klitos Kyriacou
09/28/2022, 9:12 AMDouble.deg and Double.rad so they both return Angle , and Angle.toRadians(): Double (trivially returns the value) and Angle.toDegrees(): Double (converts value held in radians to degrees).elect
10/07/2022, 7:56 AMoverloading by return type which is not possiblecant
@JvmName helps with that?ephemient
10/07/2022, 7:59 AMelect
10/07/2022, 8:26 AMephemient
10/07/2022, 8:30 AMephemient
10/07/2022, 8:32 AMelect
10/07/2022, 8:33 AMJvmNames the dev could specify the name to be used underneath (and visible from Java)ephemient
10/07/2022, 8:35 AM