execstr fixed about third argument. 03/17103/2
Cedric Delamarre [Tue, 25 Aug 2015 13:14:02 +0000 (15:14 +0200)]
execstr("a=1;a(3)","errcatch","m")

Change-Id: Ia7c6a2770fff378af83d940b91eb8c3bee96541d

scilab/modules/functions/sci_gateway/cpp/sci_execstr.cpp

index e582384..258a3c7 100644 (file)
@@ -215,7 +215,7 @@ Function::ReturnValue sci_execstr(types::typed_list &in, int _iRetCount, types::
     }
     catch (const ast::InternalError& ie)
     {
-        if (bErrCatch == false && bMute == false)
+        if (bErrCatch == false)
         {
             delete pExp;
             ConfigVariable::macroFirstLine_end();
@@ -223,6 +223,11 @@ Function::ReturnValue sci_execstr(types::typed_list &in, int _iRetCount, types::
             throw ie;
         }
 
+        if (bMute == false)
+        {
+            scilabForcedWriteW(ie.GetErrorMessage().c_str());
+        }
+
         ConfigVariable::resetWhereError();
         iErr = ConfigVariable::getLastErrorNumber();
     }