comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Problem with EXIT and garbage collection
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Problem with EXIT and garbage collection [message #90940 is a reply to message #90887] Fri, 15 May 2015 03:41 Go to previous message
penteado is currently offline  penteado
Messages: 866
Registered: February 2018
Senior Member
Administrator
Hello,

This is very odd behavior. I can confirm it happens on IDL 8.3 and 8.4 under Linux. Also, if garbage collection is disabled, with heap_refcount(), the problem does not happen.

Paulo

On Tuesday, May 5, 2015 at 6:05:44 PM UTC-3, Mike Galloy wrote:
> If I have a routine like this that uses garbage collection and does not
> explicitly free its memory:
>
> pro test
> compile_opt strictarr
>
> o = list()
> ; obj_destroy, o
>
> exit, status=1
> end
>
> And, run it from the command line like below, I get a strange error:
>
> $ idl -e test
> IDL Version 8.4, Mac OS X (darwin x86_64 m64). (c) 2014, Exelis
> Visual Information Solutions, Inc.
>
> % Compiled module: TEST.
> % Can't return from the main level.
> % Execution halted at: $MAIN$ 8
>
> If I uncomment the OBJ_DESTROY, I get what I want:
>
> $ idl -e test
> IDL Version 8.4, Mac OS X (darwin x86_64 m64). (c) 2014, Exelis
> Visual Information Solutions, Inc.
>
> % Compiled module: TEST.
> $ echo $?
> 1
>
> Mike
> --
> Michael Galloy
> www.michaelgalloy.com
> Modern IDL: A Guide to IDL Programming (http://modernidl.idldev.com)
[Message index]
 
Read Message
Read Message
Previous Topic: Re: Help extracting a single column from dat file
Next Topic: Spawn under Mac Os Yosemite

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 14:10:41 PDT 2025

Total time taken to generate the page: 0.00485 seconds