Skip to content

Commit 3c22866

Browse files
committed
[C++]: Helper function to produce the needed number of closing braces.
1 parent 1b82901 commit 3c22866

File tree

1 file changed

+5
-0
lines changed
  • sbe-tool/src/main/java/uk/co/real_logic/sbe/generation/cpp

1 file changed

+5
-0
lines changed

sbe-tool/src/main/java/uk/co/real_logic/sbe/generation/cpp/CppUtil.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,4 +139,9 @@ public static String formatByteOrderEncoding(final ByteOrder byteOrder, final Pr
139139
return "";
140140
}
141141
}
142+
143+
public static String closingBraces(final int count)
144+
{
145+
return new String(new char[count]).replace("\0", "};\n");
146+
}
142147
}

0 commit comments

Comments
 (0)