[cmake-developers] [CMake 0013220]: In trace mode, evaluated 'elseif'/'else' commands are not printed
Mantis Bug Tracker
mantis at public.kitware.com
Mon May 14 19:52:11 EDT 2012
The following issue has been SUBMITTED.
======================================================================
http://public.kitware.com/Bug/view.php?id=13220
======================================================================
Reported By: Brian Helba
Assigned To:
======================================================================
Project: CMake
Issue ID: 13220
Category: (No Category)
Reproducibility: have not tried
Severity: minor
Priority: normal
Status: new
======================================================================
Date Submitted: 2012-05-14 19:52 EDT
Last Modified: 2012-05-14 19:52 EDT
======================================================================
Summary: In trace mode, evaluated 'elseif'/'else' commands
are not printed
Description:
In trace mode ('--trace'), only the opening 'if' command of a conditional block
is printed. If the opening 'if' command evaluates False, any subsequent
'elseif'/'else' statements will be evaluated by CMake ('else' is a trivial
evaluation), but not printed.
Determining which 'elseif'/'else' commands were evaluated can still be done
implicitly, by examining which set of consequent commands are evaluated.
However, actually printing which 'elseif'/'else' commands are evaluated would
make trace mode more usable and consistent (since 'if' evaluation is printed).
Steps to Reproduce:
For "test.cmake":
IF(0)
COMMAND1()
ELSEIF(0)
COMMAND2()
ELSEIF(1)
COMMAND3()
ELSE()
COMMAND4()
ENDIF()
Current output in trace mode ("cmake --trace -P test.cmake"):
test.cmake(1): IF(0 )
test.cmake(6): COMMAND3( )
Preferred output would be:
test.cmake(1): IF(0 )
test.cmake(3): ELSEIF(0 )
test.cmake(5): ELSEIF(1 )
test.cmake(6): COMMAND3( )
======================================================================
Issue History
Date Modified Username Field Change
======================================================================
2012-05-14 19:52 Brian Helba New Issue
======================================================================
More information about the cmake-developers
mailing list