This line is prone to throwing IllegalArgumentExceptions in calls such as
ops.op("namespace.name").inType(Foo.class, Bar.class).apply()
This call generates an OpRef looking for a BiFunction<Foo, Bar, Object>. If there is no satisfying BiFunction, adapt will try to look for an adaptor that can generate one. If adaptOpOutputSatisfiesRefTypes() can find an adapt Op to generate the appropriate BiFunction, the output O will not be assigned to a Type and thus substituteTypeVariables cannot substitute the O for some other Type.
Solutions include:
- Modifying
inferTypeVariables to put some dummy type (i.e. an Any) into the Map
- Handling the error throwing within
substituteTypeVariables better.
Unfortunately, I was rushed in thinking out this error report, so more details to come.
This line is prone to throwing
IllegalArgumentExceptions in calls such asops.op("namespace.name").inType(Foo.class, Bar.class).apply()This call generates an
OpReflooking for aBiFunction<Foo, Bar, Object>. If there is no satisfyingBiFunction, adapt will try to look for an adaptor that can generate one. IfadaptOpOutputSatisfiesRefTypes()can find anadaptOp to generate the appropriateBiFunction, the outputOwill not be assigned to aTypeand thussubstituteTypeVariablescannot substitute theOfor some otherType.Solutions include:
inferTypeVariablesto put some dummy type (i.e. anAny) into theMapsubstituteTypeVariablesbetter.Unfortunately, I was rushed in thinking out this error report, so more details to come.