at least move the funciton, otherwise its under a wrong header in doxygen