No, you should not rely on this. You must define your own comparison function. Of course, this means that you have to raise it through datastructures (in order to be able to compare, say, open_pt lists), but this is a safe thing when you need a comparison function for the domain.
Please note that extended standard libraries, such as Batteries or Kernel, provide helper functions to raise comparisons across all common data structures to help you expand your comparison to a specific domain with any type containing open_pt .
Edit: Note that you can rely on this, since the ordering of mutable constructors is specified in the OCaml / C interface . I don't think it's a good idea, though, what if you need to include closures inside your argument argument next time?
source share