May 16, 2022
On 5/16/2022 1:29 PM, H. S. Teoh wrote:
> This is not really a big problem. Just search for `dlang` instead of `D`
> and you get good results.

Or 'D Programming'. When I search for C stuff, I use 'C Programming'. Both work well.
May 17, 2022
On Tuesday, 17 May 2022 at 00:50:53 UTC, max haughton wrote:
>
> ...
>
> https://github.com/rust-lang/rust-bindgen
>
> It's not built in to the compiler but it's officially supported by the Rust foundation.

in the hands of advanced Rustcracians who come from a C background, I don't feel too uncomfortable with this.

in the same way I don't feel uncomfortable about Walter using ImportC (given his extensive expertise in C and D).

but making it easily available for the mass of beginners out there (and even the mass of intermediates), worries me. C is profoundly unsafe.

I'd rather they were focused on safer programming practices ;-)

Of course, the C ABI is so simple, it's always going to be temptation to interact with it. Couple that with all the C code out there, the tempation is very high indeed.

How on earth are we ever going to move the world of software away from C?

The answer is ( I suspect) - when mass societal consequences occur (e.g. a cyber war outbreak or some really widespread consequential disaster - and we end finding out, they targeted all our C platforms.

Only then will we have sufficient impetus to get off our butts and do something about our extensive reliance on what is arguably, the most unsafe language of all -> C.

May 17, 2022
On Tuesday, 17 May 2022 at 01:57:44 UTC, forkit wrote:
> How on earth are we ever going to move the world of software away from C?
>
> The answer is ( I suspect) - when mass societal consequences occur (e.g. a cyber war outbreak or some really widespread consequential disaster - and we end finding out, they targeted all our C platforms.
>
> Only then will we have sufficient impetus to get off our butts and do something about our extensive reliance on what is arguably, the most unsafe language of all -> C.

Too much "we," not enough "I."
May 17, 2022
On Tuesday, 17 May 2022 at 01:57:44 UTC, forkit wrote:
>

'here be dragons' -> case in point..

"are you sure that's right?"

https://youtu.be/1H9FHhRntAk?t=199




May 17, 2022
On Tuesday, 17 May 2022 at 02:05:54 UTC, StarCanopy wrote:
> On Tuesday, 17 May 2022 at 01:57:44 UTC, forkit wrote:
>> How on earth are we ever going to move the world of software away from C?
>>
>> The answer is ( I suspect) - when mass societal consequences occur (e.g. a cyber war outbreak or some really widespread consequential disaster - and we end finding out, they targeted all our C platforms.
>>
>> Only then will we have sufficient impetus to get off our butts and do something about our extensive reliance on what is arguably, the most unsafe language of all -> C.
>
> Too much "we," not enough "I."

But I cannot do it ;-)

It *must* be 'we'.

(same with global warming I guess).

having said that, the first line I write in a D module, is -> @safe:

how many others can say the same?


May 17, 2022

On Tuesday, 17 May 2022 at 01:57:44 UTC, forkit wrote:

>

Only then will we have sufficient impetus to get off our butts and do something about our extensive reliance on what is arguably, the most unsafe language of all -> C.

Actually, C is one of the few languages in use where there are industtial verification solutions...

Anyway, D has always followed C semantics and has always been system level. It never claimed not to be.

People who care a lot about correctness now use Rust, compilers for such languages are implemented in Rust. In that narrow space Rust cannot be displaced in the next 10 years.

Yet, Skia, Z3, LLVM and other big performance libraries will remain in C in the next 10 years. Nobody wants to rewrite those in other languages. Nobody can afford to build competitive free alternatives. So, C it is!

ImportC done well allows D to benefit from the selfimposed restriction of being C-like that has been there from day 1.

The only way to do it well is to do an integration that drills down to the level of the lexer, parser and AST.

May 17, 2022
On Tuesday, 17 May 2022 at 02:43:31 UTC, Ola Fosheim Grøstad wrote:
>
> People who care a lot about correctness now use Rust, compilers for such languages are implemented in Rust. In that narrow space Rust cannot be displaced in the next 10 years.
>

yes. I have to agree here. Rust is really the only contender at the moment.

D's 'incrementing C by 1', was never going to be enough :-(

But D4.. or .. D10... could be different.

But I doubt it will be.

In the meantime, pls everyone, write @safe: at the beggining of your module, and then you'll have no choice, but to explicately choose unsafe mode 'manually'

(as opposed to an unsafe environment being presented to you, by default).

If you can't choose to be safe, at least choose to be unsafe ;-)

May 17, 2022

On Tuesday, 17 May 2022 at 02:43:31 UTC, Ola Fosheim Grøstad wrote:

>

On Tuesday, 17 May 2022 at 01:57:44 UTC, forkit wrote:

>

[...]

Actually, C is one of the few languages in use where there are industtial verification solutions...

[...]

Z3 and LLVM are not written in C, unless you mean the stable APIs to them.

The Z3 C++ interface is actually implemented on top of the C API.

May 17, 2022

On Tuesday, 17 May 2022 at 02:43:31 UTC, Ola Fosheim Grøstad wrote:

>

On Tuesday, 17 May 2022 at 01:57:44 UTC, forkit wrote:

>

Only then will we have sufficient impetus to get off our butts and do something about our extensive reliance on what is arguably, the most unsafe language of all -> C.

Actually, C is one of the few languages in use where there are industtial verification solutions...

Anyway, D has always followed C semantics and has always been system level. It never claimed not to be.

People who care a lot about correctness now use Rust, compilers for such languages are implemented in Rust. In that narrow space Rust cannot be displaced in the next 10 years.

Yet, Skia, Z3, LLVM and other big performance libraries will remain in C in the next 10 years. Nobody wants to rewrite those in other languages. Nobody can afford to build competitive free alternatives. So, C it is!

ImportC done well allows D to benefit from the selfimposed restriction of being C-like that has been there from day 1.

The only way to do it well is to do an integration that drills down to the level of the lexer, parser and AST.

Other than memory safety rust doesn't have all that many virtues beyond any other language for guaranteeing correctness.

Ada remains the top dog for properly critical software. SPARK still does not have many proper challengers in the space.

May 17, 2022

On Tuesday, 17 May 2022 at 04:34:16 UTC, max haughton wrote:

>

Other than memory safety rust doesn't have all that many virtues beyond any other language for guaranteeing correctness.

Ada remains the top dog for properly critical software. SPARK still does not have many proper challengers in the space.

Rust is getting attention from people/academics who design/explore/research/implement tooling with a focus on correctness. They have the momentum at this point.