Has a way to get the datatype in C?
For example:
int foo; if (foo is int) { // do something }
or something like:
if (typeof(foo
This is called type introspection or reflection and is not supported by the C language. You would probably have to write your own reflection library, and it would be a significant effort.