Using a simpler function instead of a complex macro.