News for hackers. Stuff that matters.
Re:How generics are implemented in Go 1.18 by Kranar on Tuesday March 01, 2022 @04:13PM (#30520067)
Not really, in C++ templates still need to be instantiated in every module but modules don't have to each repeat the parsing of template definitions. The module that declares the template will do the job of parsing the template and producing some intermediate representation of it that other modules can consume. Okay that does save some amount of time but the overwhelming majority of time spent compiling templates is in instantiating them, not parsing them from literal text into an AST.

Modules don't make instantiating templates any faster, it only makes parsing them faster.

Re:How generics are implemented in Go 1.18 by pjmlp on Wednesday March 02, 2022 @04:02AM (#30525339)
They sure do, make the most common expansions avaiable as extern templates.
Re:How generics are implemented in Go 1.18 by Kranar on Wednesday March 02, 2022 @09:43AM (#30527837)
That has nothing to do with modules. You can extern a template going back to C++11.
Re:How generics are implemented in Go 1.18 by pjmlp on Wednesday March 02, 2022 @11:03AM (#30528810)
Modules make it more convinient to do so, and allow for more build speedups.