BatmanAoD

joined 2 years ago
[–] BatmanAoD@programming.dev 2 points 4 days ago

You don't have to imagine it; you can browse the Linux Kernel mailing list!

[–] BatmanAoD@programming.dev 3 points 4 days ago (2 children)

That's called a mailing list

/s

[–] BatmanAoD@programming.dev 1 points 5 days ago (1 children)

I think generally C compilers prefer to keep the stack intact for debugging and such.

[–] BatmanAoD@programming.dev 1 points 5 days ago (3 children)

Okay, yeah, I was indeed reading your original reply as a criticism of one of the people involved (presumably the security researcher), rather than as a criticism of the post title. Sorry for misunderstanding.

Apparently GCC does indeed do tail-call optimization at -O2: https://gcc.gnu.org/onlinedocs/gcc/Optimize-Options.html#index-foptimize-sibling-calls

But in that case, I'm not sure why the solution to the denial of service vulnerability isn't just "compile with -foptimize-sibling-calls."

[–] BatmanAoD@programming.dev 2 points 6 days ago (5 children)

...what is your point? Some software (in a language that doesn't have tail-recursion optimization) used recursion to handle user-provided input, and indeed it broke. Someone wrote to explain that that's a potential vulnerability, the author agreed, and fixed it. Who here is misunderstanding how computers implement recursion?

[–] BatmanAoD@programming.dev 8 points 1 week ago

TypeScript is a language, and traditionally languages are considered separate from their implementations. When I first saw the headline I hoped maybe it meant a non-JS runtime for compiled TS, and I'm well aware of the difference. Yes, that would be a much larger undertaking than porting the compiler to a new language, but the headline doesn't indicate how large a project this is, and Microsoft certainly has the resources to write a new backend (even a native-code one) for the TS compiler.

[–] BatmanAoD@programming.dev 1 points 3 weeks ago

What about Julia?

[–] BatmanAoD@programming.dev 6 points 3 weeks ago (3 children)

Is Fortran really your favorite language?

[–] BatmanAoD@programming.dev 2 points 4 weeks ago

What's wrong with the Windows one, and/or what's better about Gnome's or KDE's?

[–] BatmanAoD@programming.dev 2 points 4 weeks ago

They did consider making environment-manipulation functions atomic; the problem is that there's simply no way to guarantee that everything that can manipulate your process's environment is actually beholden to whatever atomic interface Rust provides. I could be misremembering, but I think there was even some discussion with glibc maintainers about whether this could be made safe, and the answer was basically "haha no."

[–] BatmanAoD@programming.dev 2 points 4 weeks ago (2 children)

What virtual desktops do you prefer? I don't find Mac OS's significantly better, and I haven't spent much time with very many Linux window managers other than i3 (and that was years ago).

69
submitted 2 months ago* (last edited 2 months ago) by BatmanAoD@programming.dev to c/programmer_humor@programming.dev
 
34
submitted 1 year ago* (last edited 1 year ago) by BatmanAoD@programming.dev to c/rust@programming.dev
 

Almost five years ago, Saoirse "boats" wrote "Notes on a smaller Rust", and a year after that, revisited the idea.

The basic idea is a language that is highly inspired by Rust but doesn't have the strict constraint of being a "systems" language in the vein of C and C++; in particular, it can have a nontrivial (or "thick") runtime and doesn't need to limit itself to "zero-cost" abstractions.

What languages are being designed that fit this description? I've seen a few scripting languages written in Rust on GitHub, but none of them have been very active. I also recently learned about Hylo, which does have some ideas that I think are promising, but it seems too syntactically alien to really be a "smaller Rust."

Edit to add: I think Graydon Hoare's post about language design choices he would have preferred for Rust also sheds some light on the kind of things a hypothetical "Rust-like but not Rust" language could do differently: https://graydon2.dreamwidth.org/307291.html

view more: next ›