Trivial question re: callbacks

Started by Daimoth, September 14, 2015, 13:11:47

Previous topic - Next topic

Daimoth

Why is "fun" commonly appended to the end of callback identifiers? EX, line 35 I'm assuming it stands for function, but isn't that implied? Is it a holdover from another language?

FortressBuilder

It's most likely from C. There you pass actual function pointers instead of wrapping your code in separate callback classes. GLFW also uses it.

spasi

Yes, ignore it. The "fun" postfix is part of the C type of GLFW callback functions.

Daimoth

Thanks. I'll probably keep fun on just for the hell of it.