C++ (C too) header-only libraries are badhttps://schneide.wordpress.com/2018/04/30/c-header-only-libraries-are-bad/ …
-
-
"portability/drop-in argument" comes from people who use VS only and manually editing projects...
-
I use VS only. I generally manuallly edit the project. Lol. Then again, I only depend on D3D11, Imgui, and OpenAL. A lib has to solve a problem I really don’t want to solve myself before I will consider using it.
- Näytä vastaukset
Uusi keskustelu -
-
-
Spend the extra 5 minutes to drop in a header and link a lib. You don’t do it that often (or at least, you shouldn’t — this isn’t JavaScript). Moreover, few libs are small, useful, and solving a sufficiently difficult problem enough to be header only.
Kiitos. Käytämme tätä aikajanasi parantamiseen. KumoaKumoa
-
-
-
Readability is in no way significantly impacted by putting things in one file and you don't have to inline everything in a single file library. This is the strangest bikeshed honestly.
-
Inlining comment I'll bow out to. Readability I won't. I've seen header-only libs that are 80% utilities and setup all on top. Bottom 20% are things I actually want. When all in one file, difficult to understand what is what, where separations are.
- Näytä vastaukset
Uusi keskustelu -
Lataaminen näyttää kestävän hetken.
Twitter saattaa olla ruuhkautunut tai ongelma on muuten hetkellinen. Yritä uudelleen tai käy Twitterin tilasivulla saadaksesi lisätietoja.