maco call: avoid declare variable if 'slot' is already used by a named argument 48/19548/1
Antoine ELIAS [Fri, 24 Nov 2017 11:26:05 +0000 (12:26 +0100)]
Change-Id: I832c650a7cba61aa05edddd0d9b2b2e03be695c7

scilab/modules/ast/src/cpp/types/macro.cpp

index fdc0149..e1cfc8f 100644 (file)
@@ -258,7 +258,7 @@ Callable::ReturnValue Macro::call(typed_list &in, optional_list &opt, int _iRetC
 
         for (i = m_inputArgs->begin(), j = in.begin(); j != in.end(); ++j, ++i)
         {
-            if (*j)
+            if (*j && (*j)->isListInsert() == false)
             {
                 //prevent assignation of NULL value
                 pContext->put(*i, *j);