seems weird to include almost 6k sloc of code for two functions... Is there something smaller we can use?