Small utility functions