Common utilities by Sébastien Lucas