Commit Graph

6 Commits

Author SHA1 Message Date
Kitware Robot 9db3116226 Remove CMake-language block-end command arguments
Ancient versions of CMake required else(), endif(), and similar block
termination commands to have arguments matching the command starting the
block.  This is no longer the preferred style.

Run the following shell code:

for c in else endif endforeach endfunction endmacro endwhile; do
    echo 's/\b'"$c"'\(\s*\)(.\+)/'"$c"'\1()/'
done >convert.sed &&
git ls-files -z -- bootstrap '*.cmake' '*.cmake.in' '*CMakeLists.txt' |
egrep -z -v '^(Utilities/cm|Source/kwsys/)' |
egrep -z -v 'Tests/CMakeTests/While-Endwhile-' |
xargs -0 sed -i -f convert.sed &&
rm convert.sed
2012-08-13 14:19:16 -04:00
Kitware Robot 77543bde41 Convert CMake-language commands to lower case
Ancient CMake versions required upper-case commands.  Later command
names became case-insensitive.  Now the preferred style is lower-case.

Run the following shell code:

cmake --help-command-list |
grep -v "cmake version" |
while read c; do
    echo 's/\b'"$(echo $c | tr '[:lower:]' '[:upper:]')"'\(\s*\)(/'"$c"'\1(/g'
done >convert.sed &&
git ls-files -z -- bootstrap '*.cmake' '*.cmake.in' '*CMakeLists.txt' |
egrep -z -v '^(Utilities/cm|Source/kwsys/)' |
xargs -0 sed -i -f convert.sed &&
rm convert.sed
2012-08-13 14:19:16 -04:00
Brad King 267085f338 ENH: Improve strictness of Function test
The command "set(... PARENT_SCOPE)" should never affect the calling
scope.  This improves the Function test to check that such calls in a
subdirectory scope affect the parent but not the child.
2009-07-22 13:42:27 -04:00
Alexander Neundorf fc8ce17433 ENH: remove RAISE_SCOPE() again and instead add SET(<var> <value> PARENT_SCOPE)
Alex
2008-01-18 15:52:54 -05:00
Ken Martin ac4c2f675a ENH: change raise_scope signature to be safer for returned varuables 2008-01-03 11:22:33 -05:00
Brad King dcd9a1b59f BUG: Make RAISE_SCOPE function work when variable is not defined. 2008-01-02 17:49:16 -05:00