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

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

[Octave-bug-tracker] [bug #50640] display function not passing arguments


From: John W. Eaton
Subject: [Octave-bug-tracker] [bug #50640] display function not passing arguments to overloaded version of function
Date: Wed, 29 Mar 2017 14:41:18 -0400 (EDT)
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Firefox/45.0

Follow-up Comment #23, bug #50640 (project octave):

OK, after thinking about it some more, I change Octave so that it never calls
the display function with more than one input argument since this is not
documented Matlab behavior and it was causing trouble for existing Octave
classes.  I did that instead of checking whether a display function for a
class is defined to accept one or two arguments and call it differently based
on this determination, because that is more work and the feature is
undocumented in Matlab anyway.

I modified the documentation for the built-in display function so that it
doesn't mention the two-argument version, but I left it as before so that
things like


display (1, 'foo')


will work when there is no overloaded display method (as they do in Matlab).

I've also fixed the display methods in Octave that I found so that they always
use inputname instead of a second argument.

Here are the changesets:

http://hg.savannah.gnu.org/hgweb/octave/rev/7d4ca8c01bbb
http://hg.savannah.gnu.org/hgweb/octave/rev/b636f10ce53f

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?50640>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

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