octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #57449] struct2hdl fails to set property with


From: Rik
Subject: [Octave-bug-tracker] [bug #57449] struct2hdl fails to set property with erroneous "invalid value"
Date: Fri, 20 Dec 2019 11:44:33 -0500 (EST)
User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; Trident/7.0; rv:11.0) like Gecko

Follow-up Comment #3, bug #57449 (project octave):

I think both conventions are reasonable.  Not creating an object if it cannot
be rendered as the programmer intended (for example, because property/value
pairs are incorrect) makes it clear that something is wrong to the user.  And,
for laziness, this behavior is already programmed in to Octave.

On the other hand, Octave does not have to follow Matlab on this convention if
we don't want to.  I would say that try/catch blocks aren't that expensive in
terms of performance and struct2hdl isn't called in the innermost loops of
functions so it is not going to be a hot spot in the code.  Performance is
probably more related to how many properties you can modify in one call to
set() versus multiple calls.

You could ask about changing the default behavior on the Octave Maintainers
e-mail list if you wanted to get an opinion about going forward.  If they
think it is a good idea then you could submit your patched up struct2hdl.m to
this bug report for review. 


    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?57449>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]