C++ at the End of 2022

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

Our great sponsors
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • SaaSHub - Software Alternatives and Reviews
  • carbon-lang

    Carbon Language's main repository: documents, design, implementation, and related tools. (NOTE: Carbon Language is experimental; see README)

    > I like Rust's pragmatism.

    Me too.

    But Scala is also a very pragmatic language. If you want something academic go for Haskell.

    > Allow limited operator overload.

    Nitpick: Scala does not have any operators. So it doesn't have operator overloading at all.

    Scala simulates operators by infix method syntax.

    Instead of writing `1.+(2)` you can just write `1 + 2`. But the later is the same method call as the first one!

    > Eschew HKT for a simpler abstractions.

    AFAIK HKTs are more or less "just postponed" in Rust, AFAIK.

    People would like to add them of course. The discussion goes on forever by now. Some small insight (there is much more when you look for it):

    https://github.com/rust-lang/rfcs/issues/324

    https://internals.rust-lang.org/t/higher-kinded-types-the-di...

    > Don't go in the deep end with type power, nor too much in opposite direction and avoid any complicated feature.

    While having a full ML style type system with afine types on top, and quite some other type level mechanics up to singleton types?

    Sure sure, no power in here. :-)

    > The more powerful feature the more abusable it is, and Scala loves the power at all cost.

    Everything is "abusable". This is not an argument.

    But that Scala loves power at all cost is simply not true. The contrary is.

    Just to cite one of the most influential post in Scala land of all times:

    https://www.lihaoyi.com/post/StrategicScalaStylePrincipleofL...

    This, and the BDFL constantly complaining about unnecessary complex code people write speaks for itself.

    Scala lately even reduced the power of some features just to prevent "abuse". (Which is partly an overreaction; but that's another story).

    > Why would anyone care? The more flexible/powerful something is the harder it will be to parse by humans and tooling.

    That's also not true.

    Scala has a very small and simple syntax (despite all the language features).

    Scala is on the surface much much simpler and much more regular then Rust!

    https://github.com/e3b0c442/keywords

    (You could also compare the language grammars. This would be even more in favor of Scala in this regard).

    Scala 3 looks even almost like Python!

    https://docs.scala-lang.org/scala3/book/scala-for-python-dev...

    > Plus Scala has the big deal breaker. GC and no custom primitive types.

    What a "deal breaker"?

    https://github.com/carbon-language/carbon-lang/blob/trunk/do...

    You've seen this here in the thread?

    Also:

    https://docs.scala-lang.org/overviews/core/value-classes.htm...

    As soon as Valhalla lands in JVM-land this will be full blown value types without any limitations.

    And in Scala Native you can have of course native structs today. (Only that Scala Native isn't ready for prime time just now).

    In the long run Scala Native could also run without GC. The Caprese project will bring something that is more powerful than Rust lifetimes. Lifetimes will fall out as a special case of a more general concept.

    > > Besides that: The Rust people are looking envious. I've read about some ideas that were more or less a direct copy of Scala's implicits.

    > What do you mean exactly?

    Implicits get discussed every now and than in Rust land. Even the above Rust internals discussion start with them.

    Or this here:

    https://tmandry.gitlab.io/blog/posts/2021-12-21-context-capa...

    Also I've once read something that looked like a brain storming for future Rust features. They came up with more or less implicits (only that they didn't call them like that, so I can't find this any more, didn't bookmark it).

    Someone even once proposed directly Scala's implicits for Rust. But this went nowhere as the other people on the forum actually didn't understand them (which was no wonder as the example was quite terrible and the proponent was not really experienced with Scala so couldn't explain it well). People came than to quite wrong conclusions (some of them even mixed implicits in general even the dreaded implicit conversions, which were in fact mostly overused and caused trouble in Scala; but things got redesigned exactly because of that).

  • hylo

    The Hylo programming language

    Also, https://www.val-lang.dev/ seems more interesting. And http://www.jot.fm/issues/issue_2022_02/article2.pdf

    > Safe by default: Val’s foundation of mutable value semantics ensures that ordinary code is memory safe, typesafe, and data-race-free. By explicit, auditable opt-in, programmers can use unsafe constructs for performance where necessary, and can build safe constructs using unsafe ones.

    Versus Carbon:

    > Carbon's premise is that C++ users can't give up performance to get safety.

    https://github.com/carbon-language/carbon-lang/blob/trunk/do...

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

  • flecs

    A fast entity component system (ECS) for C & C++

    there are several, following slightly different designs [0]. entt and flecs (mix C/C++) are currently the most visible [1]. older and more established engines are getting into the game as well [2].

    its just a data point that C++ has constituencies that have not given up on it yet.

    [0] https://github.com/topics/ecs?l=c%2B%2B&o=desc&s=forks

    [1] https://github.com/SanderMertens/flecs

    [2] https://github.com/GodotECS

  • papers

    ISO/IEC JTC1 SC22 WG21 paper scheduling and management (by cplusplus)

  • rfcs

    RFCs for changes to Rust

    > I like Rust's pragmatism.

    Me too.

    But Scala is also a very pragmatic language. If you want something academic go for Haskell.

    > Allow limited operator overload.

    Nitpick: Scala does not have any operators. So it doesn't have operator overloading at all.

    Scala simulates operators by infix method syntax.

    Instead of writing `1.+(2)` you can just write `1 + 2`. But the later is the same method call as the first one!

    > Eschew HKT for a simpler abstractions.

    AFAIK HKTs are more or less "just postponed" in Rust, AFAIK.

    People would like to add them of course. The discussion goes on forever by now. Some small insight (there is much more when you look for it):

    https://github.com/rust-lang/rfcs/issues/324

    https://internals.rust-lang.org/t/higher-kinded-types-the-di...

    > Don't go in the deep end with type power, nor too much in opposite direction and avoid any complicated feature.

    While having a full ML style type system with afine types on top, and quite some other type level mechanics up to singleton types?

    Sure sure, no power in here. :-)

    > The more powerful feature the more abusable it is, and Scala loves the power at all cost.

    Everything is "abusable". This is not an argument.

    But that Scala loves power at all cost is simply not true. The contrary is.

    Just to cite one of the most influential post in Scala land of all times:

    https://www.lihaoyi.com/post/StrategicScalaStylePrincipleofL...

    This, and the BDFL constantly complaining about unnecessary complex code people write speaks for itself.

    Scala lately even reduced the power of some features just to prevent "abuse". (Which is partly an overreaction; but that's another story).

    > Why would anyone care? The more flexible/powerful something is the harder it will be to parse by humans and tooling.

    That's also not true.

    Scala has a very small and simple syntax (despite all the language features).

    Scala is on the surface much much simpler and much more regular then Rust!

    https://github.com/e3b0c442/keywords

    (You could also compare the language grammars. This would be even more in favor of Scala in this regard).

    Scala 3 looks even almost like Python!

    https://docs.scala-lang.org/scala3/book/scala-for-python-dev...

    > Plus Scala has the big deal breaker. GC and no custom primitive types.

    What a "deal breaker"?

    https://github.com/carbon-language/carbon-lang/blob/trunk/do...

    You've seen this here in the thread?

    Also:

    https://docs.scala-lang.org/overviews/core/value-classes.htm...

    As soon as Valhalla lands in JVM-land this will be full blown value types without any limitations.

    And in Scala Native you can have of course native structs today. (Only that Scala Native isn't ready for prime time just now).

    In the long run Scala Native could also run without GC. The Caprese project will bring something that is more powerful than Rust lifetimes. Lifetimes will fall out as a special case of a more general concept.

    > > Besides that: The Rust people are looking envious. I've read about some ideas that were more or less a direct copy of Scala's implicits.

    > What do you mean exactly?

    Implicits get discussed every now and than in Rust land. Even the above Rust internals discussion start with them.

    Or this here:

    https://tmandry.gitlab.io/blog/posts/2021-12-21-context-capa...

    Also I've once read something that looked like a brain storming for future Rust features. They came up with more or less implicits (only that they didn't call them like that, so I can't find this any more, didn't bookmark it).

    Someone even once proposed directly Scala's implicits for Rust. But this went nowhere as the other people on the forum actually didn't understand them (which was no wonder as the example was quite terrible and the proponent was not really experienced with Scala so couldn't explain it well). People came than to quite wrong conclusions (some of them even mixed implicits in general even the dreaded implicit conversions, which were in fact mostly overused and caused trouble in Scala; but things got redesigned exactly because of that).

  • keywords

    A list and count of keywords in programming languages.

    > I like Rust's pragmatism.

    Me too.

    But Scala is also a very pragmatic language. If you want something academic go for Haskell.

    > Allow limited operator overload.

    Nitpick: Scala does not have any operators. So it doesn't have operator overloading at all.

    Scala simulates operators by infix method syntax.

    Instead of writing `1.+(2)` you can just write `1 + 2`. But the later is the same method call as the first one!

    > Eschew HKT for a simpler abstractions.

    AFAIK HKTs are more or less "just postponed" in Rust, AFAIK.

    People would like to add them of course. The discussion goes on forever by now. Some small insight (there is much more when you look for it):

    https://github.com/rust-lang/rfcs/issues/324

    https://internals.rust-lang.org/t/higher-kinded-types-the-di...

    > Don't go in the deep end with type power, nor too much in opposite direction and avoid any complicated feature.

    While having a full ML style type system with afine types on top, and quite some other type level mechanics up to singleton types?

    Sure sure, no power in here. :-)

    > The more powerful feature the more abusable it is, and Scala loves the power at all cost.

    Everything is "abusable". This is not an argument.

    But that Scala loves power at all cost is simply not true. The contrary is.

    Just to cite one of the most influential post in Scala land of all times:

    https://www.lihaoyi.com/post/StrategicScalaStylePrincipleofL...

    This, and the BDFL constantly complaining about unnecessary complex code people write speaks for itself.

    Scala lately even reduced the power of some features just to prevent "abuse". (Which is partly an overreaction; but that's another story).

    > Why would anyone care? The more flexible/powerful something is the harder it will be to parse by humans and tooling.

    That's also not true.

    Scala has a very small and simple syntax (despite all the language features).

    Scala is on the surface much much simpler and much more regular then Rust!

    https://github.com/e3b0c442/keywords

    (You could also compare the language grammars. This would be even more in favor of Scala in this regard).

    Scala 3 looks even almost like Python!

    https://docs.scala-lang.org/scala3/book/scala-for-python-dev...

    > Plus Scala has the big deal breaker. GC and no custom primitive types.

    What a "deal breaker"?

    https://github.com/carbon-language/carbon-lang/blob/trunk/do...

    You've seen this here in the thread?

    Also:

    https://docs.scala-lang.org/overviews/core/value-classes.htm...

    As soon as Valhalla lands in JVM-land this will be full blown value types without any limitations.

    And in Scala Native you can have of course native structs today. (Only that Scala Native isn't ready for prime time just now).

    In the long run Scala Native could also run without GC. The Caprese project will bring something that is more powerful than Rust lifetimes. Lifetimes will fall out as a special case of a more general concept.

    > > Besides that: The Rust people are looking envious. I've read about some ideas that were more or less a direct copy of Scala's implicits.

    > What do you mean exactly?

    Implicits get discussed every now and than in Rust land. Even the above Rust internals discussion start with them.

    Or this here:

    https://tmandry.gitlab.io/blog/posts/2021-12-21-context-capa...

    Also I've once read something that looked like a brain storming for future Rust features. They came up with more or less implicits (only that they didn't call them like that, so I can't find this any more, didn't bookmark it).

    Someone even once proposed directly Scala's implicits for Rust. But this went nowhere as the other people on the forum actually didn't understand them (which was no wonder as the example was quite terrible and the proponent was not really experienced with Scala so couldn't explain it well). People came than to quite wrong conclusions (some of them even mixed implicits in general even the dreaded implicit conversions, which were in fact mostly overused and caused trouble in Scala; but things got redesigned exactly because of that).

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts