Use cl-flet instead flet for newer version of Emacs.