Hello, no, it's not possible to inspect the stack and query the type of values on the stack.
This has been asked before. Please let us know, if this missing feature is a show blocker for you. Those methods exists internally. We always hesitate in extending the C-API.
You say: "I have an application that needs to pass a variable number of parameters to a C function".
C-functions with a variable number of parameters may introduce compilation problems: the compiler (not only Genero fglcomp, also c4gl) checks the number of parameters. You can not call a c-function with different number of parameters from the same 4gl-moudule.
$ c4gl xx.4gl || cat xx.err
The compilation was not successful. Errors found: 1.
The file "xx.err" has been written.
MAIN
CALL foo(1)
CALL foo(1, 2)
|
| The function "foo" has already been called with a different
| number of parameters.
| See error number -4333.
END MAIN
Rene