Skip to content

sbeTool 1.12.2 generates uncompilable code #648

Closed
@ssmlp001

Description

@ssmlp001

schema:
<field id="8" name="stopType" type="String16Type" presence="required" sinceVersion="7" />

generates below code

   public void getStopType(final Appendable value)
    {
        if (parentMessage.actingVersion < 7)
        {
            return "";   <---- this doesn't compile
        }

        for (int i = 0; i < 16 ; ++i)
        {
            final int c = buffer.getByte(this.offset + 1112 + i) & 0xFF;
            if (c == 0)
            {
                break;
            }
            try
            {
                value.append(c > 127 ? '?' : (char)c);
            }
            catch (final java.io.IOException e)
            {
                throw new java.io.UncheckedIOException(e);
            }
        }
    }

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions