Using clang-format with C++/CLI “for each”
问题 I currently try to format C++/CLI code using clang-format (version 9.0.0). I cannot figure how to handle for each statements. Before: for each (auto i in I) { } After (say, CTRL-K/CTRL-D in Visual Studio): for each (auto i in I) { } I read here this: ...you might want to change ForEachMacros to add "for each" I tried this: ForEachMacros: - for each - foreach - Q_FOREACH - BOOST_FOREACH then this: ForEachMacros: - 'for each' and this: - "for each" and even this: - "for\s+each" Nothing works.