octave-maintainers
[Top][All Lists]
Advanced

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

Re: rename typeinfo


From: Carlo de Falco
Subject: Re: rename typeinfo
Date: Fri, 25 Jun 2010 16:13:06 +0200


On 25 Jun 2010, at 15:06, address@hidden wrote:

Yeah, but what gave you the impression you should use it? You typed
"help typeinfo", read that it returns the "type of the expression",
and concluded that this is what you want. If it said "*internal* type,
you likely want to use class for normal programming", you would follow
this advice.

Actually "typeinfo" can itself be useful to users.
I once had a problem with a function producing a memory overflow because

>> typeinfo ([eye(4), sprandn(4,4,.25)])
ans = sparse matrix

while

>> typeinfo ([eye(4), eye(4)])
ans = matrix

how could I ever have debuged this with "class"?

I believe nobody uses functions he doesn't know before he reads what
they do, if someone does, he can't be helped anyway.

c.


reply via email to

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