apache/couchdb-couch — pull request #23 by davisp (2014-12-12 20:31:39+00:00)
Title: Add IS_OLD_RECORD macro

This can be used in guards to detect if a state variable needs to be
upgraded. An example of it's use might be:

handle_call(Msg, From, St) when ?IS_OLD_RECORD(St, #st{}) ->
handle_call(Msg, From, upgrade_state(St));

This is useful for upgrading any of our various gen behaviors that
aren't properly supervised.

COUCHDB-2511