<html>
  <head>
    <meta content="text/html; charset=windows-1252"
      http-equiv="Content-Type">
  </head>
  <body link="#0B6CDA" text="#000000" vlink="#551A8B" alink="#EE0000"
    bgcolor="#ffffff">
    <div class="moz-cite-prefix">Le 16/02/2016 12:21, <a class="moz-txt-link-abbreviated" href="mailto:amonmayr@laas.fr">amonmayr@laas.fr</a> a
      écrit :<br>
    </div>
    <blockquote cite="mid:56C30628.9050505@laas.fr" type="cite">
      <meta content="text/html; charset=windows-1252"
        http-equiv="Content-Type">
      <div class="moz-cite-prefix">Le 02/16/2016 11:55 AM, Eric Dubois a
        écrit :<br>
      </div>
      <blockquote
cite="mid:CAGgDjFRjsFUUeHZ00WOgy1QziEGrTpSamJ_E1rdqestMwb6+RQ@mail.gmail.com"
        type="cite">
        <div dir="ltr">
          <div>.../...
            <p class="MsoNormal" style="margin-bottom:0.0001pt"><span
                style="font-size:12pt;font-family:Arial,sans-serif"
                lang="EN-US">More worrying still, not all additions or
                subtractions involving null matrices will generate
                errors when switching from Scilab 5 or older to Scilab
                6: for example, z=size([a+1 y],1) applied to the null
                matrix a will simply add 1 in Scilab 6 to the result of
                Scilab 5, without generating errors. </span></p>
          </div>
        </div>
      </blockquote>
    </blockquote>
    .<br>
    It does:<br>
    --> a=[]; y = 3; z=size([a+1 y],1) <br>
    operation +: Warning adding a matrix with the empty matrix will give
    an empty matrix result.<br>
     z  = <br>
    <br>
       1.<br>
    <br>
    <blockquote cite="mid:56C30628.9050505@laas.fr" type="cite">
      <blockquote
cite="mid:CAGgDjFRjsFUUeHZ00WOgy1QziEGrTpSamJ_E1rdqestMwb6+RQ@mail.gmail.com"
        type="cite">
        <div dir="ltr">
          <div>
            <p class="MsoNormal" style="margin-bottom:0.0001pt"><span
                style="font-size:12pt;font-family:Arial,sans-serif"
                lang="EN-US">The attentive user will be alerted by the
                warning message generated by Scilab 6, but the
                inattentive one may not notice it or fully understand
                its consequences. </span></p>
          </div>
        </div>
      </blockquote>
    </blockquote>
    This is why, fortunately, unworkaroundly, a new <tt>warning("stop")</tt>
    synopsis has been implemented. Announcements and Releases notes
    failed announcing and stressing on it:<br>
    <pre style="font-style: normal; font-size: 12px;"><tt><span style="color:rgb(0,0,0);">warning</span></tt><tt> </tt><tt><span style="color:rgb(0,0,0);">stop</span></tt><tt>
</tt><tt><span style="color:rgb(176,24,19);">function</span></tt><tt> </tt><tt><span style="color:rgb(0,0,0);">test</span></tt><tt><span style="color:rgb(74,85,219);">(</span></tt><tt><span style="color:rgb(74,85,219);">)</span></tt><tt>
    </tt><tt><span style="color:rgb(0,0,0);">a</span></tt><tt><span style="color:rgb(92,92,92);">=</span></tt><tt><span style="color:rgb(74,85,219);">[</span></tt><tt><span style="color:rgb(74,85,219);">]</span></tt><tt><span style="color:rgb(0,0,0);">;</span></tt><tt> </tt><tt><span style="color:rgb(0,0,0);">y</span></tt><tt> </tt><tt><span style="color:rgb(92,92,92);">=</span></tt><tt> </tt><tt><span style="color:rgb(188,143,143);">3</span></tt><tt><span style="color:rgb(0,0,0);">;</span></tt><tt> </tt><tt><span style="color:rgb(0,0,0);">z</span></tt><tt><span style="color:rgb(92,92,92);">=</span></tt><tt><span style="color:rgb(0,0,0);">size</span></tt><tt><span style="color:rgb(74,85,219);">(</span></tt><tt><span style="color:rgb(74,85,219);">[</span></tt><tt><span style="color:rgb(0,0,0);">a</span></tt><tt><span style="color:rgb(92,92,92);">+</span></tt><tt><span style="color:rgb(188,143,143);">1</span></tt><tt> </tt><tt><span style="color:rgb(0,0,0);">y</span></tt><tt><span sty
le="color:rgb(74,85,219);">]</span></tt><tt><span style="color:rgb(0,0,0);">,</span></tt><tt><span style="color:rgb(188,143,143);">1</span></tt><tt><span style="color:rgb(74,85,219);">)</span></tt><tt> 
</tt><tt><span style="color:rgb(176,24,19);">endfunction</span></tt><tt>
</tt><tt><span style="color:rgb(0,0,0);">test</span></tt><tt><span style="color:rgb(74,85,219);">(</span></tt><tt><span style="color:rgb(74,85,219);">)

<font color="#000000">--> warning stop

--> function test()
  >     a=[]; y = 3; z=size([a+1 y],1) 
  > endfunction

--> test()
operation +: Warning adding a matrix with the empty matrix will give an empty matrix result.
at line     2 of function test 

*** Execution stopped after a warning. ***
Set warning("on") to continue execution after a warning.
</font></span></tt></pre>
    <tt></tt><br>
    <span style="color:rgb(74,85,219);"><font color="#000000">Again and
        again and again, more and more publicity MUST be done about how
        to translate Scilab 5 code and modules into SCilab 6 code and
        modules.</font></span><br>
    <span style="color:rgb(74,85,219);"><font color="#000000">For the
        moment, S/E fails on that.</font></span><br>
    <span style="color:rgb(74,85,219);"></span><br>
    <br>
    <blockquote cite="mid:56C30628.9050505@laas.fr" type="cite">
      <blockquote
cite="mid:CAGgDjFRjsFUUeHZ00WOgy1QziEGrTpSamJ_E1rdqestMwb6+RQ@mail.gmail.com"
        type="cite">
        <div dir="ltr">
          <div>.../...
            <p class="MsoNormal" style="margin-bottom:0.0001pt"><span
                style="font-size:12pt;font-family:Arial,sans-serif"
                lang="EN-US">Don’t other Scilab users share my concern?</span></p>
          </div>
        </div>
      </blockquote>
    </blockquote>
    .<br>
    Sure i did. This is why i claimed for a warning, and for a way to
    get the where() trace.<br>
    <br>
    <blockquote cite="mid:56C30628.9050505@laas.fr" type="cite">
      <blockquote
cite="mid:CAGgDjFRjsFUUeHZ00WOgy1QziEGrTpSamJ_E1rdqestMwb6+RQ@mail.gmail.com"
        type="cite">
        <div dir="ltr">
          <div> </div>
        </div>
      </blockquote>
      Le 16/02/2016 12:21, <a class="moz-txt-link-abbreviated" href="mailto:amonmayr@laas.fr">amonmayr@laas.fr</a> a écrit :<br>
      <br>
      Well, I understand your concern.<br>
      However, I buy the fact that this change will make the language
      more consistent.<br>
      Indeed, "ms=m+s" where m is a matrix and s a scalar gives a matrix
      ms of same size than m in most cases (ie when m is not empty).<br>
      It thus makes sense that adding a scalar to an empty matrix
      returns an empty matrix.<br>
      This is also the default behavior with other similar languages
      like octave, matlab, julia, so it makes sense.<br>
      I think the old behavior was kind of weird.<br>
      But you are right that this is a major change that will introduce
      subtle and hard to find bugs.<br>
      We should keep in mind that it's a major change (5.x->6.x) </blockquote>
    .<br>
    This is why IMO all major changes should be done now, not postponed
    for Scilab 6.x. For my part, i will refuse reviewing all my codes
    several times after 6.0.<br>
    For instance : <a class="moz-txt-link-freetext" href="http://bugzilla.scilab.org/14287">http://bugzilla.scilab.org/14287</a> should be fixed
    before the final 6.0 release, or tagged WONTFIX.<br>
    <br>
    <br>
    <blockquote cite="mid:56C30628.9050505@laas.fr" type="cite">and I
      think the last one (4.x->5.x) was even worse in terms of
      backward compatibility!<br>
    </blockquote>
    .<br>
    I don't think so, by far. The new graphical system -- that was the
    main change -- was already implemented in 4.  As far as i remember,
    5. mainly removed the old graphical system that was still supported
    in addition to the new one (by the way, there are still some traces
    of the oldies... For instance, xset() is still unremoved, in 95%
    duplicate of set() that was introduced (but still with some features
    unported to set()) ).<br>
    <br>
    Regards<br>
    Samuel Gougeon<br>
    <br>
  </body>
</html>