| Re: Object method name problem [message #12580] |
Wed, 26 August 1998 00:00 |
J.D. Smith
Messages: 214 Registered: August 1996
|
Senior Member |
|
|
Ken Kobayashi wrote:
>
> Hi,
>
> I am experimenting with using objects in IDL 5.0, and have
> encountered a little problem. I defined a new object (call it myobj),
> and also wrote a method called 'plot'. When I call myobj->plot, IDL
> dumps core and crashes. But when I explicitely compile the
> myobj__plot.pro file before calling the method, it runs just fine. Is
> IDL trying to run the wrong program? I thought that regular
> procedures and object methods don't share the name space, but are
> there still liminatiosn that prohibit the use of common names like
> 'plot'?
>
> Ken Kobayashi
> kobaken@din.or.jp
This was a bug I pointed out in version 5.0, fixed in version 5.0.3, with
description from the release text:
==> Object procedure naming
IDL now properly checks the number of arguments required
for object procedure methods that have the same name as
IDL system procedures.
I would recommend an upgrade to the latest version, 5.11 (which, by the way,
fixes the arg_present issue with _REF_EXTRA which had me so bothered).
JD
--
J.D. Smith |*| WORK: (607) 255-5842
Cornell University Dept. of Astronomy |*| (607) 255-6263
304 Space Sciences Bldg. |*| FAX: (607) 255-5875
Ithaca, NY 14853 |*|
|
|
|
|