Live data from Hacker News

Trip report: Summer ISO C++ standards meeting in Varna, Bulgaria

herbsutter.com

11–20 of 141 posts

Re: Trip report: Summer ISO C++ standards meeting in Varna, Bulgaria

#11
post #7
post #3

Earlier quoted context omitted.

Same for "safety"

reflection seems almost dead but there are 2 papers listed on Herb's summary that directly relate to safety: P2530 hazaerd pointers https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2023/p25... P2757 type checking for std::format https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2023/p27...

Yeah, hazard pointers address one of the very common sources of memory safety problems (iterator invalidation). It's definitely not a magic solution that solves all problems, especially given that none of the standard library containers will use them, but they're a very useful tool.

Re: Trip report: Summer ISO C++ standards meeting in Varna, Bulgaria

#12
post #6

Earlier quoted context omitted.

I for one welcome the new features! I don't think it's too hard to learn a few new things every 3 years.

You have to think about newbies too. Python has made the same mistake as C++, but worse. At least C++ is not pretending to be user friendly. "Modern" C++ was a mountain to climb for me. I think I will not even try to catch up on modules, contracts and what not. I'd rather go back to C for personal projects. I just don't have the stamina for another big C++ language change. And they add up.

While I don't follow Python development super closely, as a scripting language it is still pretty simple and user friendly. I'm sure once the complexity rises... well, the complexity rises.

Re: Trip report: Summer ISO C++ standards meeting in Varna, Bulgaria

#13
post #3
post #2

Ctrl+f "Reflection" -> 0 results Maybe next year ..

Same for "safety"

If you are waiting for a Rust-like feature that guarantees memory safety - this won't happen. Changes to the language required for this would break too much. Also, existing code wouldn't compile anymore because it contains a ton of memory bugs.

Re: Trip report: Summer ISO C++ standards meeting in Varna, Bulgaria

#14
post #6

Earlier quoted context omitted.

I for one welcome the new features! I don't think it's too hard to learn a few new things every 3 years.

You have to think about newbies too. Python has made the same mistake as C++, but worse. At least C++ is not pretending to be user friendly. "Modern" C++ was a mountain to climb for me. I think I will not even try to catch up on modules, contracts and what not. I'd rather go back to C for personal projects. I just don't have the stamina for another big C++ language change. And they add up.

It's not only about newbies in the end. When I started learning C++ back in ~2000 the semi-joke was that "C++ takes about 10 years to learn". The language is far bigger now, with more things you either need to know to cut out or somehow just not learn, but then you need to learn it if you end up working with code that uses it, etc.. This stuff, to use properly, usually comes with a list of "dos and don'ts" in C++ so it's not feasible to just on-demand learn the additions to the language and call it a day.

Re: Trip report: Summer ISO C++ standards meeting in Varna, Bulgaria

#15

I feel things with C++ are not as bad as with Python, but I would really like a "core language freeze" for 10 years now or something. I don't want to keep up with all these changes. To many enthusiasts on the committee.

You don’t have to, though over time some of them will start to appear in other peoples’ code.

A lot of features aren’t fully fleshed out when they enter the standard. For example the building blocks of coroutines appeared in C++20 but the user friendly affordances aren’t there yet — but with the building blocks in place people can work on that.

Likewise a lot of features are there for library developers and aren’t needed by regular code.

So your position is sorta consistent with what’s mostly approved by the committee. Even ranges, which are exciting, I’m still waiting on to see if some things get shaken out.

Re: Trip report: Summer ISO C++ standards meeting in Varna, Bulgaria

#16
post #6

Earlier quoted context omitted.

I for one welcome the new features! I don't think it's too hard to learn a few new things every 3 years.

You have to think about newbies too. Python has made the same mistake as C++, but worse. At least C++ is not pretending to be user friendly. "Modern" C++ was a mountain to climb for me. I think I will not even try to catch up on modules, contracts and what not. I'd rather go back to C for personal projects. I just don't have the stamina for another big C++ language change. And they add up.

But newbies typically don't need to learn the whole mountain.

* Some new features are typically added to handle very specific cases that will rarely be encountered but can't be easily handled by existing mechanisms. These are typically used by library authors to make an API clearer or easier to use, and new developers won't need to interact with them at all.

* Some new features are added to replace existing features either partially or entirely (because the old feature had issues, or a better way of handling it was found). In that case, new developers just don't need to learn the old feature at all, or if they do, they can learn it later as a more advanced technique.

I don't know a huge amount of C++, and I haven't been following Python much recently, but to use some examples from Rust:

* GATs and a lot of the newer trait features are very much in the former category. Very few Rust developers will be directly using the new tools, but library authors can use them to create easier-to-use APIs which benefit everyone.

* The `try` mechanism is often simpler to learn than all the Result/Option combinators, which drastically reduces the amount a new developer needs to know about to get started. You'll still probably need those combinators later, but you can now get started without them.

There are definitely some features that don't fit clearly into these two categories, and add a kind of overall complexity to the language. But I think a lot of people look at a big list of features and think "but that will be so much to learn", forgetting that (a) you probably don't need to learn a lot of it until you're already very advanced, and (b) a lot of it will be making other parts of the language obsolete and overall simpler.

Re: Trip report: Summer ISO C++ standards meeting in Varna, Bulgaria

#17

I am very happy to see that the work on fibers is continuing. I was under the impression that with the addition of coroutines, the focus would have shifted. Glad i am wrong. What's the best way for someone to keep track of the progress and the conversation around a specific proposal ?

https://www.open-std.org/jtc1/sc22/wg21/docs/papers/ has all the papers. To follow discussions, it's probably best to attend the standard meeting online or in person.

Re: Trip report: Summer ISO C++ standards meeting in Varna, Bulgaria

#18
No pictures of Varna?

That's a bit sad. It's a beautiful city, in places - the older buildings (neglected), the waterfront park that stretches KILOMETERS, one of the best puppet museums in Europe, and an incredible nature reserve parallel to the beach, out of town to the north...

Re: Trip report: Summer ISO C++ standards meeting in Varna, Bulgaria

#19

No pictures of Varna? That's a bit sad. It's a beautiful city, in places - the older buildings (neglected), the waterfront park that stretches KILOMETERS, one of the best puppet museums in Europe, and an incredible nature reserve parallel to the beach, out of town to the north...

There are two reasons for that: Herb didn't attend in person and the meeting was in Golden Sands, not Varna...

Re: Trip report: Summer ISO C++ standards meeting in Varna, Bulgaria

#20
post #6

Earlier quoted context omitted.

I for one welcome the new features! I don't think it's too hard to learn a few new things every 3 years.

You have to think about newbies too. Python has made the same mistake as C++, but worse. At least C++ is not pretending to be user friendly. "Modern" C++ was a mountain to climb for me. I think I will not even try to catch up on modules, contracts and what not. I'd rather go back to C for personal projects. I just don't have the stamina for another big C++ language change. And they add up.

it feels like the problem isn't number of features, but quality of learning material...

what ways are there to learn/teach latest c++? I can only come up with conferences' recordings

Post reply on HN