* Marc Haber: >> What happens if there are multiple ~? > > They are processed in order. > > dpkg --compare-versions handles ~ correctly.
And APT? Does it behave differently? (There are differences between the two in the area of epoch handling.) I'm going to add something like the following: - Split the version strings u, v at ~ into components (u_1, ..., u_m), (v_1, ..., v_n). - If m = 0 and m > 0, then we have v < u. - If m = 0 and m = 0, then u = v is the result. - If m > 0 and n = 0, then u < v. - Otherwise, m,n > 0. If u_1 < v_1, then u < v is the result. Conversely, v_1 < u_1 means v < u. But if u = v, recursively compare (u_2, ..., u_m) and (v_2, ..., v_n) using this algorithm. Does this sound reasonable? (There are a few corner cases involving empty components and leading and trailing zeros, but let's ignore them for now, until there is a complete specification.) -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]