5 ms·
People are downvoting but the GP's point does not really have anything to do with type systems. I think this example is closer to macro expansion than a typesys
by adamwk 5y ago
People are downvoting but the GP's point does not really have anything to do with type systems. I think this example is closer to macro expansion than a typesystem.
- jcelerier 5y agoHow is paramerization of types on values not a typesystem-level property ? There's definitely nothing akin to macro expansion involved since you can do type-level computations that way
- throwaway17_17 5y agoI’m pretty sure the implication is that since template instances are made specific at compile time and are done so in a way that is very analogous to AST based macro expansion. Specifically, C++ templates are a programming language which runs during the compilation of C++ code that acts by producing valid C++ AST components.
- jcelerier 5y agoI have never seen a definition of type system which cares about things being done at compile-time or runtime, or that there even is a compile-time or run-time