Re: Allow a sequence as a subscript

new topic     » goto parent     » topic index » view thread      » older message » newer message
euphoric said...
lpuster said...

Wishlist item:
When a function returns a location in a multi-dimensioned array, it must return a sequence. It is very messy to use the sequence to access the array.

sequence array, subscript 
array = {{1,2,3},{4,5,6},{7,8,9}} 
subscript = {2,3} 
 
array[subscript[1]][subscript[2]]   -- Current method 
 
array[subscript]   -- Wishlist alternative method 

Check out extract(). That should work for now until using a sequence to access elements is built-in.

extract() WILL NOT DO WHAT YOU WANT! extract() does something different.

Instead, see fetch() - http://oe.cowgar.com/docs/eu400_0070.html#_2482_fetch

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu