You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Preferably something with older and later to be consistent with ver_oldest() and ver_latest(). A ver_ prefix would also be preferred. On the other hand, the names should not be too similar to the aforementioned functions. ver_is_older() would work well, but is_ prefix is usually connected with single argument check.
Thus, the current best is ver_older_than(). An alternative would be to have ver_compare() that returns -1, 0 and 1, but I don't like the low-level feel of this; in any case I'd want functions that return a boolean too.
The text was updated successfully, but these errors were encountered:
Use case
Comparing two version codes:
Proposed name
Preferably something with
older
andlater
to be consistent withver_oldest()
andver_latest()
. Aver_
prefix would also be preferred. On the other hand, the names should not be too similar to the aforementioned functions.ver_is_older()
would work well, butis_
prefix is usually connected with single argument check.Thus, the current best is
ver_older_than()
. An alternative would be to havever_compare()
that returns -1, 0 and 1, but I don't like the low-level feel of this; in any case I'd want functions that return a boolean too.The text was updated successfully, but these errors were encountered: