February 11, 2018
On Sunday, 11 February 2018 at 15:11:55 UTC, psychoticRabbit wrote:
> On Wednesday, 7 February 2018 at 20:30:54 UTC, Dmitry Olshansky wrote:
>> Other languages like Rust or C# (or Java) have bounds check. Plus we probably lose it in release mode, which is the mode where lurking bugs are discovered usually days after development ;) Some of these languages would prevent it on the VM level/compiler level, leaving no way to shoot yourself in the foot.
>>
>
> We all really need to get away from this idea that *we* should stop *others* from shooting themselves in the foot. People are free to do it, if they want. Who has the right to take that choice away from me?
>
> So let's NOT be like those other languages that just want to control what you do.
>
> -boundscheck=off
>
> D rocks!

That explains why there are so much SJW types in the Rust world :-)
February 11, 2018
On Sunday, 11 February 2018 at 15:11:55 UTC, psychoticRabbit wrote:
> On Wednesday, 7 February 2018 at 20:30:54 UTC, Dmitry Olshansky wrote:
>> Other languages like Rust or C# (or Java) have bounds check. Plus we probably lose it in release mode, which is the mode where lurking bugs are discovered usually days after development ;) Some of these languages would prevent it on the VM level/compiler level, leaving no way to shoot yourself in the foot.
>>
>
> We all really need to get away from this idea that *we* should stop *others* from shooting themselves in the foot. People are free to do it, if they want. Who has the right to take that choice away from me?
>
> So let's NOT be like those other languages that just want to control what you do.
>
> -boundscheck=off
>
> D rocks!

On the other hand, if my bank shoots itself in the foot it's with my money... We must definitely have ways to do it but it must be explicit and restricted to where it's useful. There is no need for -boundscheck=off in D. It is always possible to disable boundschecking locally, and that's a good thing.
February 12, 2018
On Sunday, 11 February 2018 at 15:18:20 UTC, Cym13 wrote:
>
> On the other hand, if my bank shoots itself in the foot it's with my money... We must definitely have ways to do it but it must be explicit and restricted to where it's useful. There is no need for -boundscheck=off in D. It is always possible to disable boundschecking locally, and that's a good thing.

When was the last time a bank lost customers money due not checking bounds?

It's far, far more likely you'll lose your money due to their dodgy lending practices (as many have already experienced).

February 12, 2018
On Sunday, 11 February 2018 at 15:11:55 UTC, psychoticRabbit wrote:
> On Wednesday, 7 February 2018 at 20:30:54 UTC, Dmitry Olshansky wrote:
>> Other languages like Rust or C# (or Java) have bounds check. Plus we probably lose it in release mode, which is the mode where lurking bugs are discovered usually days after development ;) Some of these languages would prevent it on the VM level/compiler level, leaving no way to shoot yourself in the foot.
>>
>
> We all really need to get away from this idea that *we* should stop *others* from shooting themselves in the foot. People are free to do it, if they want. Who has the right to take that choice away from me?

Your customers if you have any. Brcause they is inevitably you one day.

>
> So let's NOT be like those other languages that just want to control what you do.

Then pick assembly of sorts.
C ABI is a stright-jacket that ensures e.g. that your callstack is laid out correctly so that a ‘ret’ will bring you back to the call site not somewhere else. Do I need to mention libc’s machinations done “for compatibility”.

Who the fuck were these guys to steal the pleasure of misaligned stacks and wrong push/pop order? Or register save missed?

The reality is we are programming on top of increasingly complex run-times that solve low-level problems to certain extents. That includes C (even w/o libc) and pretty much any other high-level language.


>
> -boundscheck=off
>
> D rocks!


February 12, 2018
On Monday, 12 February 2018 at 04:30:38 UTC, psychoticRabbit wrote:
> On Sunday, 11 February 2018 at 15:18:20 UTC, Cym13 wrote:
>>
>> On the other hand, if my bank shoots itself in the foot it's with my money... We must definitely have ways to do it but it must be explicit and restricted to where it's useful. There is no need for -boundscheck=off in D. It is always possible to disable boundschecking locally, and that's a good thing.
>
> When was the last time a bank lost customers money due not checking bounds?
>
> It's far, far more likely you'll lose your money due to their dodgy lending practices (as many have already experienced).

As someone who's job is to audit banking and governmental systems for security vulnerabilities, I can assure you it's a real issue. Not the most common one, okay, but that doesn't make it any less dangerous.
February 12, 2018
On Monday, 12 February 2018 at 07:10:42 UTC, Cym13 wrote:
>
> As someone who's job is to audit banking and governmental systems for security vulnerabilities, I can assure you it's a real issue. Not the most common one, okay, but that doesn't make it any less dangerous.

humans auditing the work of humans - what could be more dangerous than that ;-)

February 12, 2018
On Sunday, 11 February 2018 at 15:15:45 UTC, Patrick Schluter wrote:

>
> That explains why there are so much SJW types in the Rust world :-)


No, here's why: "Rust is a systems programming language[9] sponsored by Mozilla Research"

"Mozilla" is the magic word ;)

https://en.wikipedia.org/wiki/Rust_(programming_language)

February 12, 2018
On Wednesday, 7 February 2018 at 20:30:54 UTC, Dmitry Olshansky wrote:
> On Wednesday, 7 February 2018 at 13:29:04 UTC, Mike Parker wrote:
> While an enjoable read, I fear we are aiming too low.
>
> Other languages like Rust or C# (or Java) have bounds check.

Maybe I was missing the point, but isnt the objective or the feature of the betterC mode, is to integrate C code, in a D program seamlessly by allowing to import C headers into a D program

And then from that point forward, use D features that improve on what C offers

..

Again maybe I completely misunderstood the betterC mode
but I thought that, that was it .. which justify the feature being called betterC, since this mode specifically target C

And if it was, this is not really about how advanced a language feature are

It is more how you can improve a C code based, by incrementally integrating D without loosing performance, or control





February 12, 2018
On Wednesday, 7 February 2018 at 13:29:04 UTC, Mike Parker wrote:
> Blog:
> https://dlang.org/blog/2018/02/07/vanquish-forever-these-bugs-that-blasted-your-kingdom/

Small mistake:

> Assertion failure: 'array overflow' on line 11 in file 'sum.d'

should be "line 10" there.

P.S. There is an unanswered question in the comment section.
February 13, 2018
On Monday, 12 February 2018 at 23:41:14 UTC, Bastiaan Veelo wrote:
> On Wednesday, 7 February 2018 at 13:29:04 UTC, Mike Parker wrote:
>> Blog:
>> https://dlang.org/blog/2018/02/07/vanquish-forever-these-bugs-that-blasted-your-kingdom/
>
> Small mistake:
>
>> Assertion failure: 'array overflow' on line 11 in file 'sum.d'
>
> should be "line 10" there.
>
> P.S. There is an unanswered question in the comment section.

Answered (the same question was also asked on reddit. O_O)

> Your comment is awaiting moderation.