| ▲ | swiftcoder an hour ago | |
> So youre saying the metaprogramming facilities of C++ allow the compiler to better optimise high level human readable code more effectively than C. The metaprogramming facilities of C++ allow the programmer to more effectively optimise than they would have the patience to do in C. The compiler's own optimisations don't directly benefit from the metaprogramming facilities in this sense. What they do is let the programmer break high level constructs down to codegen that the compiler can optimise And you could do the same things by hand in C or Rust, but it would be tedious in the extreme, and you'd probably find yourself adopting external codegen tools | ||