Comments (6)
Reproduced and fixed on "hotfix_github_9" branch. Please use it for a while.
I'm planning to do the next official release within next couple of weeks.
Also just keep in mind the following current limitations:
- Current v3.1.2 release of the COMMS library supports up to 48 variant field members.
- The "develop" branch of the COMMS library (will become v3.1.3 release soon) supports up to 128 variant members.
- The current "develop" branch of the "commsdsl" (uses "develop" branch of COMMS library) counts on limit of 128 variant members and generates member access functions itself (instead of counting on the COMMS library) in case number of used members exceeds 128.
The bottom line, if your number of variant members is below 48, use "v3.1.2" release of the COMMS library, otherwise use "develop" branch of commsdsl (also contains the recent fix from hotfix_github_9 branch) as well as "develop" branch of the COMMS library.
from commsdsl.
Ping @arobenko for help.
from commsdsl.
Additionally, if we add count to list, error reappears.
Schema
<?xml version="1.0" encoding="UTF-8"?>
<schema name="tutorial4" endian="big">
<fields>
<string name="Msg1Name" defaultValue="Message 1" />
<string name="Msg2Name" defaultValue="Message 2" />
<enum name="MsgId" type="uint8" semanticType="messageId">
<validValue name="M1" val="1" displayName="^Msg1Name" />
<validValue name="M2" val="2" displayName="^Msg2Name" />
</enum>
<enum name="PropKey" type="uint8">
<validValue name="K1" val="0" />
<validValue name="K2" val="2" />
<validValue name="K3" val="5" />
<validValue name="K4" val="10" />
<validValue name="K5" val="15" />
<validValue name="K6" val="25" />
</enum>
<int name="PropKeyCommon" type="uint8" failOnInvalid="true"/>
<variant name="KeyValueProp">
<bundle name="Prop1">
<int reuse="PropKeyCommon" name="Key" defaultValue="PropKey.K1" validValue="PropKey.K1" />
<int name="Val" type="uint16" />
</bundle>
<bundle name="Prop2">
<int reuse="PropKeyCommon" name="Key" defaultValue="PropKey.K2" validValue="PropKey.K2" />
<float name="Val" type="float" defaultValue="nan" />
</bundle>
<bundle name="Prop3">
<int reuse="PropKeyCommon" name="Key" defaultValue="PropKey.K3" validValue="PropKey.K3" />
<string name="Val">
<lengthPrefix>
<int name="Length" type="uint8" />
</lengthPrefix>
</string>
</bundle>
</variant>
<variant name="TlvProp">
<description>
Type-Length-Value Property
</description>
<members>
<bundle name="Prop4">
<int reuse="PropKeyCommon" name="Key" defaultValue="PropKey.K4" validValue="PropKey.K4" />
<int name="Length" type="uint8" semanticType="length" />
<int name="Val" type="uint32" />
</bundle>
<bundle name="Prop5">
<int reuse="PropKeyCommon" name="Key" defaultValue="PropKey.K5" validValue="PropKey.K5" />
<int name="Length" type="uint8" semanticType="length" />
<float name="Val" type="double" defaultValue="inf" />
</bundle>
<bundle name="Prop6">
<int reuse="PropKeyCommon" name="Key" defaultValue="PropKey.K6" validValue="PropKey.K6" />
<int name="Length" type="uint8" semanticType="length" />
<string name="Val" />
</bundle>
<bundle name="Any">
<int reuse="PropKeyCommon" name="Key" />
<int name="Length" type="uint8" semanticType="length" />
<data name="Val" />
</bundle>
</members>
</variant>
</fields>
<frame name="Frame">
<size name="Size">
<int name="SizeField" type="uint16" />
</size>
<id name="ID" field="MsgId" />
<payload name="Data" />
</frame>
<message name="Msg1" id="MsgId.M1" displayName="^Msg1Name">
<list name="F1" element="KeyValueProp">
<countPrefix>
<int name="Count" type="uint8" />
</countPrefix>
</list>
</message>
<message name="Msg2" id="MsgId.M2" displayName="^Msg2Name">
<list name="F2" element="KeyValueProp" count="1"/>
</message>
</schema>
from commsdsl.
from commsdsl.
Thanks for fast response!
from commsdsl.
Master branch now points to official v3.6 release that has the issue fixed.
from commsdsl.
Related Issues (20)
- Question: List without length and message size HOT 2
- ICD generation HOT 7
- Missing copyright holder in license HOT 5
- ASN.1 Parsing/Serialization HOT 2
- Adding constexpr to static const functions HOT 2
- Bit Order in `<bitfield>` and `<set>` HOT 4
- `optional` field with `cond` depending on another `optional` field. HOT 7
- Field Extension Support in Lists with termSuffix HOT 4
- Need Help HOT 21
- Creating Frame with `id` that is less than one byte HOT 3
- Can a (serial) protocol with character escaping be realized using the custom code feature? HOT 2
- Schema name cannot start with a capital HOT 4
- Select variant based on value in the transport frame HOT 1
- noexcept error with gcc 9 HOT 5
- Unexpected max serialisation length HOT 4
- Dead links in the Readme HOT 1
- vcpkg integration HOT 16
- error when using COMMSDSL_NO_TESTS HOT 2
- Undefined behaviour on "out of range" values of ID layer. HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from commsdsl.