]> https://gitweb.dealii.org/ - dealii.git/commitdiff
CMake: ensure that else() and endif() statements contain no parameter
authorMatthias Maier <tamiko@43-1.org>
Sat, 26 Nov 2022 14:05:44 +0000 (08:05 -0600)
committerMatthias Maier <tamiko@43-1.org>
Sat, 26 Nov 2022 22:52:11 +0000 (16:52 -0600)
contrib/utilities/lowercase_cmake

index d0bea70d4ad2c4a43982256f4c123b8beec08d58..d216d48712acd6f6b8d37093fac105d488644564 100755 (executable)
@@ -46,6 +46,12 @@ collect_function_names | while read command ; do
   echo 's/'"${command}"'\(\s*\)(/'"$command"'\1(/gI'
 done > "${SED_FILE}"
 
+#
+# Add rules to ensure that else() and endif() do not contain a statement.
+#
+echo 's/else([^)]*)/else()/gI' > "${SED_FILE}"
+echo 's/endif([^)]*)/endif()/gI' > "${SED_FILE}"
+
 #
 # Apply rules file to all CMake files:
 #

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.