News for hackers. Stuff that matters.
Re:Httpserver.h: Single header library for writing non-block... by nestorD on Friday December 13, 2019 @02:45AM (#21779844)
The fact that you cannot define templates out of headers also explains why C++ has a lot of header-only libraries. : if you use templates and have no global references, you are most likely already header-only.
Re:Httpserver.h: Single header library for writing non-block... by bluGill on Friday December 13, 2019 @08:19AM (#21781241)
Yeah, templates forces many C++ libraries to be header only. I suspect this came first, and only after a c++ header-only (because they had to be) libraries existed did people realize there were advantages to header only and so people wrote them where they wouldn't have to.