Is there a way to force the type of an argument in a function to be comparable?
It is not a huge problem as if the isless (or <) method is not available, it will raise an error. But I would rather enforce the type of the argument to be comparable.
Is there a way to force the type of an argument in a function to be comparable?
It is not a huge problem as if the isless (or <) method is not available, it will raise an error. But I would rather enforce the type of the argument to be comparable.
It is impossible to do this in dispatch. You can check it in the function with applicable
though that’s usually not needed and unreliable.