array typedef

2 posts / 0 new
Last post
Offline
Last seen: 11 years 4 months ago
Joined: 08/19/2013
Posts: 1
Inadvertently embiggening a typedef'd array

I have no doubt that seasoned RTI/DDS developers will spot the flaw in the following, but it's escaping me.

Given the following IDL input (call it Z.idl):

typedef struct Q
{
    long A[2];
    double B[3];
    char C[5];
} Q_t;

Compile it (using the RTI Connext 5.0.0 IDL compiler) and examine the resulting Q_t typedef:

mkdir -p temp
rtiddsgen.bat -inputIdl -ppDisable -replace -language C++ -d temp Z.idl
grep Q_t temp/Z.h | grep typedef

Keywords:
Subscribe to RSS - array typedef