Skip to content

Commit 5887a4b

Browse files
committed
genoffsets: Remove constexpr on PORT_OFFSETS array
Not sure why CLang doesn't allow this to be constexpr while GCC does, let's figure out later why this is the case. Error message: src/dynports.cc:13:45: error: constexpr variable cannot have non-literal type 'const std::array<uint16_t, 4576>' (aka 'const array<unsigned short, 4576>') static constexpr std::array<uint16_t, 4576> PORT_OFFSETS {{ ^ Signed-off-by: aszlig <[email protected]>
1 parent 5911036 commit 5887a4b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

scripts/genoffsets.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
formatted = [', '.join(['{:>5}'.format(o) for o in chunk])
2929
for chunk in chunks]
3030

31-
sig = 'static constexpr std::array<uint16_t, {}> PORT_OFFSETS'
31+
sig = 'static std::array<uint16_t, {}> PORT_OFFSETS'
3232
header = sig.format(len(offsets)) + ' {{\n '
3333
out = header + ',\n '.join(formatted) + '\n}};\n'
3434

0 commit comments

Comments
 (0)