Example : Test.idl (Test.txt attached)
Errors with : UNKNOWN = 0,
Had to Edit : UNKNOWN , // = 0,
Same enumerator names - UNKNOWN
cmake ..
-- Building for: Visual Studio 17 2022
-- Selecting Windows SDK version 10.0.19041.0 to target Windows 10.0.19044.
-- The C compiler identification is MSVC 19.30.30706.0
cmake --build .
Test.cxx(44,46): error C2365: 'orov::msg::system::UNKNOWN': redefinition; previous definition was 'enumerator'
Test.h : Edit enum to enum class
Test.cxx(46,47): error C2065: 'UNKNOWN': undeclared identifier
Test.cxx : Prefix UNKNOWN with enum name ::
m_crc_result = orov::msg::system::EChecksumResult::UNKNOWN;
m_reset_cause = orov::msg::system::EMCUResetCause::UNKNOWN;
But other statements prefix with the enum name :
Test.txt
Could fastddsgen assume the enum is enum class and prefix UNKNOWN?
m_crc_result = (orov::msg::system::EChecksumResult)enum_value;
m_reset_cause = (orov::msg::system::EMCUResetCause)enum_value;
Example : Test.idl (Test.txt attached)
Errors with : UNKNOWN = 0,
Had to Edit : UNKNOWN , // = 0,
Same enumerator names - UNKNOWN
cmake ..
-- Building for: Visual Studio 17 2022
-- Selecting Windows SDK version 10.0.19041.0 to target Windows 10.0.19044.
-- The C compiler identification is MSVC 19.30.30706.0
cmake --build .
Test.cxx(44,46): error C2365: 'orov::msg::system::UNKNOWN': redefinition; previous definition was 'enumerator'
Test.h : Edit enum to enum class
Test.cxx(46,47): error C2065: 'UNKNOWN': undeclared identifier
Test.cxx : Prefix UNKNOWN with enum name ::
m_crc_result = orov::msg::system::EChecksumResult::UNKNOWN;
m_reset_cause = orov::msg::system::EMCUResetCause::UNKNOWN;
But other statements prefix with the enum name :
Test.txt
Could fastddsgen assume the enum is enum class and prefix UNKNOWN?