Yan LR: Ignore shadow warnings in generated code
@@ -37,6 +37,9 @@ if (DEPENDENCY_PHASE)
foreach (file ${GENERATED_SOURCE_FILES_NAMES} "")
set (filepath ${CMAKE_CURRENT_BINARY_DIR}/${GRAMMAR_NAME}${file}.cpp)
set_source_files_properties (${filepath} PROPERTIES GENERATED TRUE)
+ if (CMAKE_COMPILER_IS_GNUCXX)
+ set_source_files_properties (${filepath} PROPERTIES COMPILE_FLAGS "-Wno-shadow")
+ endif (CMAKE_COMPILER_IS_GNUCXX)
list (APPEND GENERATED_SOURCE_FILES
${filepath})
endforeach (file ${GENERATED_SOURCE_FILES_NAMES})
