ReflectedGlobalFunction

Represents information about a global function (i.e. a free function) declared using $function in the Xc++ language.


$struct+ ReflectedGlobalFunction
{
    $ConstStringZ GetName() const { return m_name; }

    $ssize_t GetNumArgs() const { return m_numArgs; }
    $const ReflectedArg& GetArg(ssize_t i) const { return m_args[i]; }

    //////////////// State //////////////////
    ConstStringZ m_name;
    ReflectedReturnType m_returnType;
    const ReflectedArg* m_args;
    ssize_t m_numArgs;
    const octet_t* m_metaData;
    ConstStringZ const* m_stringTable;
    FunctionPointer m_address;
};

const ReflectedFunction& AsReflectedFunction(const ReflectedGlobalFunction& rgf)


ConstStringZ m_name

The fully qualified name of the global function represented as a pointer to a UTF-8 encoded null-terminated string (see ConstStringZ).


ReflectedReturnType m_returnType

The ReflectedReturnType records the function return type.


const ReflectedArg* m_args

Pointer to an array of ReflectedArg to record the names and types of the function arguments, or null if there are zero arguments.


ssize_t m_numArgs

The number of elements in the m_args array.


const octet_t* m_metaData

Pointer to metadata byte code on the function or null if no metadata declared.


ConstStringZ const* m_stringTable

The address of an array of pointers to UTF-8 encoded null-terminated strings (see ConstStringZ), which is the string table associated with the byte code defining the return and argument types of the function. May be null if no string table is required.


FunctionPointer m_address

The address of the global function (see FunctionPointer).