On Tuesday, 1 September 2020 at 18:20:17 UTC, Jesse Phillips
wrote:
This is going to be a hard one for me to argue but I'm going to
give it a try.
Today if you attempt to access a key from an associative array
(AA) that does not exist inside the array, a RangeError is
thrown. This is similar
On 9/4/20 1:48 AM, Jesse Phillips wrote:
On Thursday, 3 September 2020 at 15:12:14 UTC, Steven Schveighoffer wrote:
int[int] aa;
aa[4] = 5;
auto b = aa[4];
How is this code broken? It's valid, will never throw, and there's no
reason that we should break it by adding an exception into the mix.
On Thursday, 3 September 2020 at 15:12:14 UTC, Steven
Schveighoffer wrote:
int[int] aa;
aa[4] = 5;
auto b = aa[4];
How is this code broken? It's valid, will never throw, and
there's no reason that we should break it by adding an
exception into the mix.
int foo() nothrow {
return "1".to
On 9/3/20 10:43 AM, Jesse Phillips wrote:
On Tuesday, 1 September 2020 at 18:55:20 UTC, Steven Schveighoffer wrote:
On 9/1/20 2:20 PM, Jesse Phillips wrote:
Using RangeError is nice as it allows code to use array index inside
`nothrow.`
This is the big sticking point -- code that is nothrow
On Tuesday, 1 September 2020 at 18:55:20 UTC, Steven
Schveighoffer wrote:
On 9/1/20 2:20 PM, Jesse Phillips wrote:
Using RangeError is nice as it allows code to use array index
inside `nothrow.`
This is the big sticking point -- code that is nothrow would no
longer be able to use AAs. It mak
On 9/1/20 10:46 PM, James Blachly wrote:
On 9/1/20 2:55 PM, Steven Schveighoffer wrote:
On 9/1/20 2:20 PM, Jesse Phillips wrote:
Using RangeError is nice as it allows code to use array index inside
`nothrow.`
This is the big sticking point -- code that is nothrow would no longer
be able to
On 9/1/20 2:55 PM, Steven Schveighoffer wrote:
On 9/1/20 2:20 PM, Jesse Phillips wrote:
Using RangeError is nice as it allows code to use array index inside
`nothrow.`
This is the big sticking point -- code that is nothrow would no longer
be able to use AAs. It makes the idea, unfortunately,
On Tuesday, 1 September 2020 at 18:55:20 UTC, Steven
Schveighoffer wrote:
This is the big sticking point -- code that is nothrow would no
longer be able to use AAs. It makes the idea, unfortunately, a
non-starter.
You could always catch it though.
But I kinda like things the way they are exac
On 9/1/20 2:20 PM, Jesse Phillips wrote:
Using RangeError is nice as it allows code to use array index inside
`nothrow.`
This is the big sticking point -- code that is nothrow would no longer
be able to use AAs. It makes the idea, unfortunately, a non-starter.
What is wrong with using `in`?
This is going to be a hard one for me to argue but I'm going to
give it a try.
Today if you attempt to access a key from an associative array
(AA) that does not exist inside the array, a RangeError is
thrown. This is similar to when an array is accessed outside the
bounds.
```
string[string
10 matches
Mail list logo