// Can't overload this method as callee had an Object parameter, and java
// doesn't do a secondary dispatch on the true underlying type
if (constraintArg instanceof Constraint[]) {
// to support possible legacy usage of new Contraint[] {...}
return new ArgumentsMatcher((Constraint[]) constraintArg);
} else if (constraintArg instanceof Constraint) {
// to support usage of C.lt(5) type constraints
return C.args((Constraint) constraintArg);
} else {
// normal usage of the overloaded expect/match object parameter