nhs-t10 / Robotics_2021_2022

2 stars 0 forks source link

[low-priority] fix Autoauto's "incompatible native method" messages. Right now, they're... bad. we should make them more explanatory. #3

Closed chlohal closed 2 years ago

chlohal commented 2 years ago

see: org.firstinspires.ftc.teamcode.auxilary.dsls.autoauto.runtime.robotfunctions.*--

if(args.length == 1) {if(args[0] instanceof AutoautoNumericValue) {manager.cancelEncodedMovement((int)((AutoautoNumericValue)args[0]).getFloat()); return new AutoautoUndefined();}if(args[0] instanceof AutoautoString) {manager.cancelEncodedMovement(((AutoautoString)args[0]).getString()); return new AutoautoUndefined();}}

throw new org.firstinspires.ftc.teamcode.auxilary.dsls.autoauto.runtime.errors.AutoautoNoNativeMethodOverloadException("No cancelEncodedMovement with 1 args");

This is not descriptive and, more importantly, wrong. cancelEncodedMovement does have an overload with 1 arg.