The following issue has been SUBMITTED. 
====================================================================== 
http://cmake.org/Bug/view.php?id=13387 
====================================================================== 
Reported By:                Clinton Stimpson
Assigned To:                
====================================================================== 
Project:                    CMake
Issue ID:                   13387
Category:                   CMake
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     new
====================================================================== 
Date Submitted:             2012-07-09 12:13 EDT
Last Modified:              2012-07-09 12:13 EDT
====================================================================== 
Summary:                    ARGV1 scope leak
Description: 
ARGV1 values can leak into sub functions if they are optional arguments.

Steps to Reproduce: 
cmake_minimum_required(VERSION 2.8)

function(bar arg)
  set(bar_arg ${ARGV1})
  message("bar_arg=${bar_arg}")
endfunction()

function(foo arg)
  set(foo_arg "${ARGV1}")
  message("foo_arg=${foo_arg}")
  bar(${arg})
endfunction()

foo(dummy dummy2)

========

bar() was called with 1 argument, not 2.  But the ARGV1 from foo() leaked into
the ARGV1 of bar().
====================================================================== 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2012-07-09 12:13 Clinton StimpsonNew Issue                                    
======================================================================

--

Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers

Reply via email to