[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #57426] publish now fires "colon arguments sho
From: |
Rik |
Subject: |
[Octave-bug-tracker] [bug #57426] publish now fires "colon arguments should be scalars" warnings |
Date: |
Mon, 16 Dec 2019 12:45:15 -0500 (EST) |
User-agent: |
Mozilla/5.0 (Windows NT 10.0; WOW64; Trident/7.0; rv:11.0) like Gecko |
Update of bug #57426 (project octave):
Item Group: Regression => Unexpected Error
Status: None => Confirmed
_______________________________________________________
Follow-up Comment #1:
These are probably legitamate warnings. Line 902 is
## Links "<http://www.someurl.com TEXT>"
idx = strfind (cstr{j}, " ");
url = cstr{j};
url = url(2:idx-1); # Line 902
My guess is that strfind can return multiple indices because there may be
multiple spaces in the URL text. In that case, the code should pick off the
first instance with
idx = idx(1);
This is already what the colon operator is doing so there should be no change
in behavior. For example,
octave:2> idx = [3, 5]
idx =
3 5
octave:3> 1:idx
warning: colon arguments should be scalars
ans =
1 2 3
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?57426>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/