News for hackers. Stuff that matters.
Re:GCC 14 Adds Initial “-std=C++26” Plumbing by mike_hock on Saturday June 24, 2023 @09:13AM (#36458435)
Which version will come with complete "-std=c++20" support, including standard library?
Re:GCC 14 Adds Initial “-std=C++26” Plumbing by jb1991 on Saturday June 24, 2023 @09:37AM (#36458578)
I've been using the GCC 15 alpha with -std=C++32 options, which has been interesting. All the new borrow checking features and even support for fully dynamically typed programs, but it's the garbage collection that is really an enjoyable step into the future. Also glad to see C++ finally ditch inheritance and go all-in on interfaces and protocols, it's about time.
Re:GCC 14 Adds Initial “-std=C++26” Plumbing by setheron on Saturday June 24, 2023 @11:01AM (#36459256)
Wow. Neve heard of these features. Would love a link to a great write up.
Re:GCC 14 Adds Initial “-std=C++26” Plumbing by 26fingies on Saturday June 24, 2023 @11:07AM (#36459325)
i think this was a joke lol
Re:GCC 14 Adds Initial “-std=C++26” Plumbing by cuteboy19 on Saturday June 24, 2023 @11:47AM (#36459671)
I was already picturing what arcane invocation we would need to do to summon GC in a backwards compatible nin GC language
Re:GCC 14 Adds Initial “-std=C++26” Plumbing by W4RH4WK55 on Saturday June 24, 2023 @09:55AM (#36458723)
I wonder when support for modules lands so we can see that the design doesn't work out and deprecate them.

Sorry if I am too salty here, but really, it's more of a joke at this point, isn't it?

Re:GCC 14 Adds Initial “-std=C++26” Plumbing by pjmlp on Saturday June 24, 2023 @10:37AM (#36459035)
Visual C++
Re:GCC 14 Adds Initial “-std=C++26” Plumbing by dataflow on Saturday June 24, 2023 @10:26AM (#36458962)
What's wrong with their design?
Re:GCC 14 Adds Initial “-std=C++26” Plumbing by 112233 on Saturday June 24, 2023 @01:43PM (#36460880)
Re:GCC 14 Adds Initial “-std=C++26” Plumbing by dataflow on Saturday June 24, 2023 @02:04PM (#36461080)
The problems that paper points out are certainly real, but:

- They're not specific to modules (the codegen dependency issue is there even right now)

- They're not specific to C++ (Java faces a similar problem)

- They all have solutions: either you have to tell the build system what the dependencies are directly, or your compiler has to be able to build the dependencies too. Bazel and gradle already handle these, just in a different context than C++20 modules.

So while C++20 modules are harder to use, and they very well might not get adopted, it's not really a design problem, nor an unsolved one - it's just a fundamental impedance mismatch that occurs in any language where the dependencies are specified in the same file that's being compiled.

i.e. It's a problem for the build system to solve, and ones do exist that have solved other forms of it in the past.

Re:GCC 14 Adds Initial “-std=C++26” Plumbing by w4rh4wk5 on Saturday June 24, 2023 @02:45PM (#36461537)
For instance, last time I checked them out (in MSVC) it was perfectly fine to expose an un-exported type via an exported function. Apparently this is by design.

In Rust, such a thing is an error.

https://play.rust-lang.org/?version=stable&mode=debug&editio...