# Module support
if(VS_EXPERIMENTAL_MODULE)
add_compile_options(/experimental:module)
add_compile_options(/stdIfcDir "${VS_TOOLSET_PATH}/ifc/${CMAKE_VS_PLATFORM_TOOLSET_ARCHITECTURE}")
endif()
These options are forwareded to all compilers, including the NASM assambler in my case. Wrapping the options into a language specific generator expression should solve the problem.
# Module support
if(VS_EXPERIMENTAL_MODULE)
add_compile_options($<$<COMPILE_LANGUAGE:CXX>:/experimental:module>)
add_compile_options($<$<COMPILE_LANGUAGE:CXX>:/stdIfcDir> $<$<COMPILE_LANGUAGE:CXX>:"${VS_TOOLSET_PATH}/ifc/${CMAKE_VS_PLATFORM_TOOLSET_ARCHITECTURE}">)
endif()
These options are forwareded to all compilers, including the NASM assambler in my case. Wrapping the options into a language specific generator expression should solve the problem.