3 ms·
Creating things from scratch is still definitely a thing, particularly for high performance code. Sure, there are plenty of data structure libraries, but squeez
by slaymaker1907 4y ago
Creating things from scratch is still definitely a thing, particularly for high performance code. Sure, there are plenty of data structure libraries, but squeezing out that last bit of performance often requires something bespoke.
For example, I recently wrote a custom CSV parser because I needed something that did no heap allocation but without mutating the original character array (using explicit string lengths).
- wombatpm 4y agoYour comment gave me flashbacks to FORTRAN data files with fixed width data descriptors.
- inimino 4y agoThis is a ton of fun! If you have the double-quote escaping then you have to mutate the data in place, but if it's just a table of numbers then not. Usually CSV parsing doesn't matter, but when it does, it matters a lot.