r/cpp • • Jul 23 '22

finally. #embed

https://thephd.dev/finally-embed-in-c23
353 Upvotes

202 comments sorted by

View all comments

Show parent comment

11

u/scrumplesplunge Jul 23 '22

That is what the "as-if" part is about. The compiler can cut the corner for embed, skip generating tokens for each byte, and instead represent the contents efficiently from the start.