Open GTValentine opened 6 years ago
Making this optional seems like a reasonable thing for Djinni to do. Is the definition required at C++11 level? If so we couldn't eliminate it entirely while maintaining compatibility. At any rate, feel free to phrase your request in the form of a Pull Request. 😄
Meanwhile, you can likely work around this by tweaking the build options for generated code compared to your own code. I've frequently had to do that for 3rd-party code, which generally isn't as warning-clean as we want our internal code to be.
There's no option to suppress constexpr members declarations. For this .djinni file:
Two files will be generated:
and
MSVC with c++17 enabled though frowns upon that:
warning C5041: 'FOO': out-of-line definition for constexpr static data member is not needed and is deprecated in C++17
.We're compiling with
/WX
(warning treated as errors) so this broke our build.Please provide an option to not generate the declarations.