On Mon, Feb 20, 2017 at 12:54 PM, Ryan Gonzalez wrote:
> elements = [mylist[a], mylist[b]]
> - Right now, a[b,c] is already valid syntax, since it's just indexing a
> with the tuple (b, c). The proposal is to make this a specialization in the
> grammar, and also allow stuff like a[b:c, d:e] (like
On 20 February 2017 at 20:54, Ryan Gonzalez wrote:
> Apologies if this has already been covered!
>
> Right now, if you want to get multiple elements in a list, you have to do:
>
> elements = [mylist[a], mylist[b]]
>
> My proposal is two-folded:
>
> - Right now, a[b,c] is already valid syntax, sinc
On 20 February 2017 at 22:05, Jonathan Goble wrote:
> On Mon, Feb 20, 2017 at 3:55 PM Ryan Gonzalez wrote:
>
>> - Right now, a[b,c] is already valid syntax, since it's just indexing a
>> with the tuple (b, c). The proposal is to make this a specialization in the
>> grammar, and also allow stuff
On Mon, Feb 20, 2017 at 3:55 PM Ryan Gonzalez wrote:
> - Right now, a[b,c] is already valid syntax, since it's just indexing a
> with the tuple (b, c). The proposal is to make this a specialization in the
> grammar, and also allow stuff like a[b:c, d:e] (like
> `a.__getitem__(slice(b, c), slice(d
So, to make sure I have this right: your proposal says array should be
indexable by a list of indexes as they're currently done, in a tuple,
right? Would this also mean that something like (1:4, 8:10, 13) should be
an acceptable constructor for a tuple?
-Ryan Birmingham
On 20 February 2017 at 15:
Apologies if this has already been covered!
Right now, if you want to get multiple elements in a list, you have to do:
elements = [mylist[a], mylist[b]]
My proposal is two-folded:
- Right now, a[b,c] is already valid syntax, since it's just indexing a
with the tuple (b, c). The proposal is to m