<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<p>Hi,</p>
<p>I completely agree with Samuel !</p>
<p>S.<br>
</p>
<div class="moz-cite-prefix">Le 09/02/2021 à 12:27, Samuel Gougeon a
écrit :<br>
</div>
<blockquote type="cite"
cite="mid:f51cfcb8-8d83-f8cb-d129-eaa9d7855c91@free.fr">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<div class="moz-cite-prefix">Hello Federico,</div>
<div class="moz-cite-prefix"><br>
</div>
<div class="moz-cite-prefix">Le 10/10/2019 à 06:33, Federico
Miyara a écrit :<br>
</div>
<blockquote type="cite"
cite="mid:58cbd60a-5380-80af-d1a2-38dd16e5adc2@fceia.unr.edu.ar">
<meta http-equiv="content-type" content="text/html;
charset=UTF-8">
<br>
<font face="Courier New">Dear all,<br>
<br>
I wonder why the function "exists" yields 1 or 0 as doubles,
instead of boolean. I know there is little distinction between
booleans and {0, 1} and can be easily converted back and
forth. I also know that Scilab is not meant to be a strongly
typed language. But wouldn't it make more sense that this kind
of funtion yielded a boolean result?<br>
<br>
It challenges reason the fact that "isreal", for instance,
yields a boolean and "exists" yields a double.<br>
</font></blockquote>
<p><br>
</p>
<p>Please use isdef() instead.</p>
<p>exists() is a pure duplicate of isdef(), except for the output
type.<br>
Converting its output into a boolean was asked 9 years ago as <a
moz-do-not-send="true"
href="https://antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/bugzilla.scilab.org/show_bug.cgi?id=10892">bug
10892</a>.</p>
<p>We should hate introducing such duplicates, that just multiply
issues and confusion with strictly no added value.<br>
This is why its removal was proposed sortly after, as <a
moz-do-not-send="true"
href="https://antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/bugzilla.scilab.org/show_bug.cgi?id=11000">bug
11000</a>.<br>
</p>
<p>To me, there is no added value either to convert exist()'s
output into boolean, except if this function is actually
removed, or at least masked, i.e. kept only for
backcompatibility reason but undocumented.</p>
<p>Best regards</p>
<p>Samuel<br>
<br>
</p>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<pre class="moz-quote-pre" wrap="">_______________________________________________
users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:users@lists.scilab.org">users@lists.scilab.org</a>
<a class="moz-txt-link-freetext" href="https://antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/users">https://antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/users</a>
</pre>
</blockquote>
<pre class="moz-signature" cols="72">--
Stéphane Mottelet
Ingénieur de recherche
EA 4297 Transformations Intégrées de la Matière Renouvelable
Département Génie des Procédés Industriels
Sorbonne Universités - Université de Technologie de Compiègne
CS 60319, 60203 Compiègne cedex
Tel : +33(0)344234688
<a class="moz-txt-link-freetext" href="http://www.utc.fr/~mottelet">http://www.utc.fr/~mottelet</a>
</pre>
</body>
</html>