Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Subjunctive
Sep 12, 2006

✨sparkle and shine✨

Athas posted:

One of the darkest events in computer history was when Guy Steele convinced Knuth to turn TeX into a programming language.

yeah, rare miss by both of them

Adbot
ADBOT LOVES YOU

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

Shaggar posted:

its not rear end to write, you need to use better toosl. creating some hosed up sudo-xml is going to cause you infinitely more wasted time than just using xml

sudo close my tags

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

they’re just strings once you serialize them. let the strings carry type information themselves, or let the schema specify it, as you prefer

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

rude and hurtful, imo

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

!!

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

NihilCredo posted:

i like the design but punting on providing a standardised schema definition language is lame

it seems slightly nicer than toml, but not enough to give up on toml's libraries. and in turn i rarely use toml because I'd rather have access to the xml/json libraries

serde and transcend format choice

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

Ralith posted:

only the most trivial stuff is format independent in serde; targeting multiple formats with the same complex structure is a non-goal

sounds like someone hasn’t transcended

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

leper khan posted:

eh. most of the security issues that aren't also problems in other languages have warnings available

yes there are flags you should enable in 2024CE. but there's heinous poo poo you can do in all languages if you ignore recommendations

are there warnings for data races or use-after-free in C in modern compilers? I haven’t honestly written pure C in a long time

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

all the modern compilers warn on stuff like gets or whatever, and the various risky str* functions, but those are easy to detect

I'm impressed by use-after-free detection, I didn't know that C compilers could model lifecycles well enough at this point!

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

so here’s an interesting thing happening in languages

Sean Baxter has apparently implemented (much of) Rust’s non-lexical lifetimes and borrow checker for C++-the-language. it’s a pretty faithful reproduction of the Rust work, down to using the same reasoning about error messages, and reading his tweet history over the past months shows an astonishing-to-me rate of progress, even with a known-working impl to reference

https://x.com/seanbax/status/1778876774832574611







this is pretty incredible, because the only other stuff that seems to be happening around memory safety in C++ is Bjarne making things worse every time he writes publicly

Google reached the conclusion a while back that there wasn’t a feasible way to do temporal safety in C++, even, which I guess is why they inflicted Carbon on themselves reluctantly

Google’s Perspective on Memory Safety posted:


We see no realistic path for an evolution of C++ into a language with rigorous memory safety guarantees that include temporal safety.

now there’s a wrinkle: Sean is apparently difficult to work with, even by the standards of the open source and C++ communities, and has been trying to find a company to buy him out on this for Very Large Amounts. the work could be worth many billions to the world if it materially improves memory safety for C++, but that’s still going to be a hard deal to make. nonetheless, Sean seems interested in seeing this work make its way through WG21 (sigh) and into standards, so there’s hope, assuming he gets over his anger that he can’t get other C++ heads to even read the NLL and ‘nomicon literature (I bet there’s more of a story there, though). there is a C++ Foundation somewhat analogous to the Rust Foundation AIUI, but even less effective, and nowhere near being able to write those cheques

the C++-insider acquaintance I chatted with about this agreed with me that the most likely path to success was a co-author appearing to assist, and he had one promising candidate in mind. hopefully Sean still gets a lot of credit once it’s all extruded through the standards process; maybe we’ll call it the Baxter Model

C++ would be growing safety-by-opt-in, which I think isn’t as good as Rust’s safety-by-default, and Rust is a much nicer (and smaller!) language to work with IMO. but if we don’t have to rewrite a ton of poo poo then honestly I think I’d be OK seeing Rust’s candle flicker out and the energy devoted to making tooling for analysis and upgrading of C++ code

very curious to hear rjmccall’s take, to whatever extent he can share it!

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

is indirecting through a filesystem remount really slow? I thought that path was OK now, but maybe that’s only on Linux

alternative might be to have the docker container be long lived, expose its own filesystem over localhost NFS, and then just “docker exec” in it to run the compiler

lots of paths to make line up, though, and stuff like inotify probably sucks

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

Athas posted:

You don't have to rewrite your C++ programs, you just shouldn't write the next one in C++.

I don't think what the world needs is another layer of sediment in the C++ specification, but I'm reluctant to tell other people what they should spend their time working on.

the problem is that when you write a program, you are generally writing the part of the iceberg that sticks above the water. “write the next one in Swift” is great, as long as the rest of the iceberg exists in Swift, or you can afford to write that stuff yourself

I think having a way to surgically make critical components checkably memory-safe would be likely to make more code safe, faster, than waiting until it is rewritten and deployed in a memory-safe language

but you are right that C++ does not lack for complexity!

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

Cybernetic Vermin posted:

like, if this is just that they can safely and without breaking backwards compatibility do a rework of c++ so that existing and future code really is improved then, yeah, that's a huge huge deal.

that’s the ambition, and afaik he still uses (most of?) the stock stdlib underneath for his examples. devils will be discovered in the details, I’m sure, but it looks to be on the right track

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

rjmccall posted:

to be fair to the broader community, c++now is specifically a “thought leadership” sort of conference, and you’d expect to find true believers heavily overrepresented there

I find that true believership isn’t generally compatible with the kind of thinking that you want leading other thinking, but that doesn’t make it uncommon indeed

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

eschaton posted:

it’s not a host OS “problem,” it’s inherent in what containers are: they’re defined as being a Linux environment, so if you’re not running Linux you have to run a VM to host containers

I don’t use Docker or containers for much of anything because I work on end user software, but for the small amount that I do use them, I use podman on macOS and it works perfectly fine and plenty fast but it runs one VM under the hood, and runs the containers under that

we’re moving away from podman on macOS for local development at work because it’s flaky when you push it with a lot of container lifecycle operations and our dev support folks are sick of the headaches. I forget what we’re doing instead, alas

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

strncpy was for working with directory tables, or something? it’s a menace

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

Sweeper posted:

we use it in protocols which have fixed width string fields still, needs suiting

you’re why we can’t remove it

Adbot
ADBOT LOVES YOU

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

eschaton posted:

just make a lil to wasm compiler and use it to compile lil on demand instead of interpreting it

V8 will go faster than this, I’m pretty sure

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply