Jump through some silly hoops to make GCC accept that a function may not always