Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » 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] Thu, 08 January 2015 04:19 Go to next message
Alexei Colin is currently offline Alexei ColinFriend
Messages: 8
Registered: October 2013
Junior Member
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 23:53 Go to previous messageGo to next message
Sasha Slijepcevic is currently offline Sasha SlijepcevicFriend
Messages: 114
Registered: July 2009
Senior Member
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] Sat, 17 January 2015 03:09 Go to previous message
Sasha Slijepcevic is currently offline Sasha SlijepcevicFriend
Messages: 114
Registered: July 2009
Senior Member
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 Sep 25 12:51:18 GMT 2018

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

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

Back to the top