c++ type information
demangle.Rddemangle gives the demangled type, sizeof its size (in bytes).
Arguments
- type
The type we want to demangle
- ...
Further argument for
cppFunction
Details
The following function is compiled and invoked:
SEXP demangle_this_type(){
typedef
return wrap( DEMANGLE(type) ) ;
}
SEXP sizeof_this_type(){
typedef
return wrap( sizeof(type) ) ;
}
DEMANGLE is a macro in Rcpp that does the work.
References
See this chapter from the GNU C++ library manual.
Author
Romain Francois <[email protected]>
Note
We only know how to demangle with gcc. If you know how to demangle types with your compiler, let us know.
See also
cppFunction is used to compile the function demangle creates.