Skip to main content



      Home
Home » Archived » DSDP - Real-Time Software Components (RTSC) » XDCspec: variable length vectors ('[]', '[length]') generate undefined type names when nested(Simple example included.)
XDCspec: variable length vectors ('[]', '[length]') generate undefined type names when nested [message #1552329] Wed, 07 January 2015 23:19 Go to next message
Eclipse UserFriend
Are nested variable-length vector fields in structures not supported?

module TestModule {
    struct TestStruct {
        // Cases 1 and 2: compile error
        UInt32 aNestedVectorField[];
        //UInt32 aNestedVectorField[length];

        // Case 3: no error
        //UInt32 aNestedVectorField[1];
    };
    config TestStruct aConfig = { aNestedVectorField: [ 42 ] };
}


package/cfg/xdctest_p86U.c:599:1: error: unknown type name '__T1_xdctest_TestModule_aNestedVectorField'
 const __T1_xdctest_TestModule_aNestedVectorField xdctest_TestModule_aConfig_aNestedVectorField__A[1];


The type that does exist (and seems to be the what the generator really means) is: __T1_xdctest_TestModule_TestStruct__aNestedVectorField. Manually typedefing the non-existant __T1_xdctest_TestModule_aNestedVectorField to __T1_xdctest_TestModule_TestStruct__aNestedVectorField allows the compilation to succeed.
Re: XDCspec: variable length vectors ('[]', '[length]') generate undefined type names when nested [message #1566596 is a reply to message #1552329] Thu, 15 January 2015 18:53 Go to previous messageGo to next message
Eclipse UserFriend
Alexei, it's the same bug as in https://www.eclipse.org/forums/index.php/t/808339/. I have it on my list of things to do, but I haven't find the time until now. I'll post again when I have a better idea how much of an effort is to fix it.
Re: XDCspec: variable length vectors ('[]', '[length]') generate undefined type names when nested [message #1568675 is a reply to message #1566596] Fri, 16 January 2015 22:09 Go to previous message
Eclipse UserFriend
There will be a fix for this problem in 3.30.06 and 3.31.00, sometimes in the next couple of weeks.
Previous Topic:XDCspec: how to use '[string]' map type? Is it only for meta?
Next Topic:statically placed memory in a struct does not seem to work
Goto Forum:
  


Current Time: Tue Jul 15 02:57:07 EDT 2025

Powered by FUDForum. Page generated in 0.24894 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top