First version of deprecation message handler code (not used yet)