4 ms·
No, not really. Closures... close on variables, function pointers, are just pointers to functions. What you are saying is sort of like saying that Classes and
by Arelius 15y ago
No, not really. Closures... close on variables, function pointers, are just pointers to functions.
What you are saying is sort of like saying that Classes and Objects are equivalent, creating a closure creates an instance, wheras a function pointer just references the canonical code.
Also, don't undervalue anonymous local functions, which is another thing that full closures have over C99 functions.