Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does not detected duplicate field id cpp #597

Closed
kdoherty2 opened this issue Oct 9, 2018 · 0 comments
Closed

Does not detected duplicate field id cpp #597

kdoherty2 opened this issue Oct 9, 2018 · 0 comments

Comments

@kdoherty2
Copy link

kdoherty2 commented Oct 9, 2018

SBE Tool v1.7.9

Given the following SBE schema

<sbe:message name="MsgSBESample2" id="1024" semanticType="MsgSBESample2">
 <field name="field1" id="1" type="uint16" presence="required" semanticType="int" />
 <field name="field2" id="1" type="uint16" presence="required" semanticType="int" />
 </sbe:message>

the SBETool generates two fields in two offsets (0,2) with the same field id.

static SBE_CONSTEXPR std::uint16_t field1Id() SBE_NOEXCEPT
{ return 1; }
 static SBE_CONSTEXPR std::size_t field1EncodingOffset() SBE_NOEXCEPT
 { return 0; }

 static SBE_CONSTEXPR std::uint16_t field2Id() SBE_NOEXCEPT
 { return 1; } 
static SBE_CONSTEXPR std::size_t field2EncodingOffset() SBE_NOEXCEPT
{ return 2; } 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants