That's scheduled for GCC 13 and was found by Sandra and Frederik, 'omp scan' has undergone quite some transformation: In 5.0 it was added with a preceding and succeeding structured block. In 5.1, 'structured block' was replaced by 'structured-block-sequence' defined as "...a sequence of two or more executable statements..." In 5.2, the s.b.s. became "... a sequence of zero or more executable statements ...". While there are restrictions against orphaned separating directives, having zero statements seems to be fine (albeit odd). The C/C++ parser already permitted >= executable statements (albeit the testcases didn't use those – and used {...} to enclose multiple executable statements). The Fortran parser was very strict and did require exactly one single executable statement before/after the scan. — Now both accept >=0. I have opt for adding a warning if there are zero statements before or after the scan. And [C/C++], while technically 'for (...)' / "#pragma omp scan ..." is valid ("for" is followed by a structured block), the before and with the attached patch there is an error if the final-loop-body does not have enclosing curly braces; I don't feel like changing the parser for such an odd use – and for any sensible use, the curly braces are required. Thoughts? Comments? * * * Warning: It seems as if nearly all warnings related to OpenMP are "0" and on by default with very few exceptions. I am wondering whether we should add a -Wopenmp and change all those 0 to warn_openmp to make it easier for the user to -Wno-openmp or -Werror=openmp - or just to '2>&1 |grep Wopenmp' to find them. Thoughts? * * * Tobias ----------------- Siemens Electronic Design Automation GmbH; Anschrift: Arnulfstraße 201, 80634 München; Gesellschaft mit beschränkter Haftung; Geschäftsführer: Thomas Heurung, Frank Thürauf; Sitz der Gesellschaft: München; Registergericht München, HRB 106955