Termination check on unionWith
问题 I'm having a problem with termination checking, very similar to the one described in this question and also this Agda bug report/feature request. The problem is convincing the compiler that the following unionWith terminates. Using a combining function for duplicate keys, unionWith merges two maps represented as lists of (key, value) pairs sorted by key. The Key parameter of a finite map is a (non-tight) lower bound on the keys contained in the map. (One reason for defining this data type is