[Scilab-users] Strange list error

Stefan Du Rietz sdr at durietz.se
Mon Jan 27 19:05:54 CET 2014


Hello Paul,
after trying like a maniac ;-) I finally managed to reproduce it!

The error shows up only when you run the command from the command 
window after a pause in the attached function testlisterror.sci.

-->testlisterror("pnonfast","nonfast")
-1->args(1) = null()
args(1) = null()
                  !--error 44
Wrong argument #2.

Without the pause it works OK.

Regards
Stefan


On 2014-01-27 08:47, Paul Bignier wrote:
--------------------
>
> Hello Stefan,
>
> What do you mean by "suddenly stopped working"? Did you switch Scilab
> versions?
>
> Could you provide us the failing test case?
> When I type
>      args = list(); args(1)=null()
> it runs smooth.
>
> Regards,
> Paul
>
>
> On 01/25/2014 09:07 PM, Stefan Du Rietz wrote:
>> I found out what the error was: I had a line
>>
>>   if exists("bolus") then
>>
>> that became true when I had this variable in the workspace, which I
>> never had before.
>>
>> I changed it to
>>
>>   if exists("bolus", "l") then
>>
>> and it worked again.
>>
>> But I still wonder: why the error 44?
>>
>> Stefan
>>
>> On 2014-01-25 18:32, Stefan Du Rietz wrote:
>> --------------------
>>> Hi all,
>>> one of my functions suddenly stopped working. During my effort to find
>>> the error by running the commands from the command window, I
>>> experienced this:
>>>
>>> -1->args(1) = null();
>>> args(1) = null();
>>>                   !--error 44
>>> Wrong argument #2.
>>>
>>> and when I checked:
>>> -1->typeof(args)
>>>   ans  =
>>>   list
>>>
>>> Can anybody explain that?
>>>
>>> Regards
>>> Stefan
>>> _______________________________________________
>>> users mailing list
>>> users at lists.scilab.org
>>> http://lists.scilab.org/mailman/listinfo/users
>>>
>>
>> _______________________________________________
>> users mailing list
>> users at lists.scilab.org
>> http://lists.scilab.org/mailman/listinfo/users
>

-------------- next part --------------
A non-text attachment was scrubbed...
Name: testlisterror.sci
Type: application/x-scilab
Size: 308 bytes
Desc: not available
URL: <https://lists.scilab.org/pipermail/users/attachments/20140127/4a89b9ce/attachment.bin>


More information about the users mailing list