Like many things, I came across this behaviour by accident. I have looked
through some of the old discussions on _Extra keyword nad was not sure
whether this has been mentioned before so here goes and I'm sure I'll find
out shortly.
heres two test procedures, one for _extra and one for _ref_extra. The idea
is they call eachother until the variable call reaches 0 or is undefined
pro test_ex,call, _EXTRA=e
print, "pro test_ex,call, _EXTRA=e "
help,e,/st
if keyword_set(call) then test_ref_ex,call-1, _ref_EXTRA=e
return
end
pro test_ref_ex,call,_REF_EXTRA=e
print, "pro test_ref_ex,call, _REF_EXTRA=e";, call
help,e,/st
if keyword_set(call) then test_ex,call-1, _EXTRA=e
return
end
--------
so here are the calls:
IDL> test_ex, /edge_trunc
pro test_ex,call, _EXTRA=e
** Structure <1d9bd10>, 1 tags, length=2, data length=2, refs=1:
EDGE_TRUNC INT 1
IDL> test_ref_ex, /edge_trunc
pro test_ref_ex,call, _REF_EXTRA=e
E STRING = Array[1]
IDL> test_ref_ex, 2, /edge_trunc
pro test_ref_ex,call, _REF_EXTRA=e
E STRING = Array[1]
pro test_ex,call, _EXTRA=e
** Structure <1d9bd10>, 1 tags, length=2, data length=2, refs=1:
EDGE_TRUNC INT 1
pro test_ref_ex,call, _REF_EXTRA=e
** Structure <1d9bd10>, 1 tags, length=2, data length=2, refs=1:
EDGE_TRUNC INT 1
IDL> test_ex, 2, /edge_trunc
pro test_ex,call, _EXTRA=e
** Structure <1d9bd10>, 1 tags, length=2, data length=2, refs=1:
EDGE_TRUNC INT 1
pro test_ref_ex,call, _REF_EXTRA=e
** Structure <1d9bd10>, 1 tags, length=2, data length=2, refs=1:
EDGE_TRUNC INT 1
pro test_ex,call, _EXTRA=e
** Structure <4850ef0>, 1 tags, length=2, data length=2, refs=1:
EDGE_TRUNC INT 1
from past discussions this is likely this is version specific, so heres the
flavor Im using:
IDL> print, !version
{ x86 Win32 Windows Microsoft Windows 5.5 Beta Jun 20 2001 32 64}
--
----------------------------------------
Martin Downing,
Clinical Research Physicist,
Grampian Orthopaedic RSA Research Centre,
Woodend Hospital, Aberdeen, AB15 6LS.
Tel. 01224 556055 / 07903901612
Fax. 01224 556662
m.downing@abdn.ac.uk
|