Hacker News new | ask | show | jobs
by falcor84 785 days ago
I feel that the site would benefit from a paragraph or two about what C++ Modules are and why devs should use them
2 comments

You know any other language that uses the header/cpp split likes C/C++ do?

This is C++es way of finally getting rid of them, akin to Swift or Rust.

It's called putting all your code in the .h
Which is going to murder your compilation times. Modules do it better, the MS Office team claims the following: Worst case: 0.9% regression compared to PCH - Best case: 21.2% improvement compared to PCH

(From https://m.youtube.com/live/H6GQUg5JquU?si=1iC_OvRQ_MprzDTQ&t...)

And what are the metrics in comparison to not using PCH?
Agreed, I’m not a C++ developer and I’ve barely guessed what’s this about
> I’m not a C++ developer and I’ve barely guessed what’s this about

I feel those statements are related.

But concepts are easily transferable, so a line or two could help a lot :)