[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #49409] Undefined var from subclass
From: |
Mike Miller |
Subject: |
[Octave-bug-tracker] [bug #49409] Undefined var from subclass |
Date: |
Sat, 22 Oct 2016 17:09:26 +0000 (UTC) |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:49.0) Gecko/20100101 Firefox/49.0 |
Update of bug #49409 (project octave):
Category: None => Interpreter
Item Group: None => Incorrect Result
Status: None => Works For Me
_______________________________________________________
Follow-up Comment #1:
Doesn't the error here just mean that you called B with only 1 argument? You
need either a default value
function obj = B(x, y = 0)
or to check the value of nargin
function obj = B(x, y)
address@hidden(x);
if (nargin > 1)
obj.y = y;
else
obj.y = ## default value
endif
If you fix that is there still a bug here?
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?49409>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/