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

Re: User selectable lower array bound?



Martin Schultz wrote:
> 
> Marc Schellens <m_schellens@hotmail.com> writes:
> 
> > Ahem:
> >
> > pro push,list,elem
> > if n_elements(list) eq 0 then list=[elem] else list=[list, elem]
> > end
> >
> > cheers,
> > marc
> 
> Won't work if elem is an array ;-( Which dimension do you append?
> And if elem is a structure you will soon need something like
> Relax_StructAssign...
> 
> Martin

As Paul pointed already out:
For your demands, write a more sophisticated routine then.
Anyway as already stated:
Everything could be so nice if c=[a,b] with noexistent a or b would
work...

marc