3 ms·
I have to admit, there have been a few times I've written comments like the following: /* Just a quick static array to get it * working. Should be en
by Periodic 17y ago
I have to admit, there have been a few times I've written comments like the following:
/* Just a quick static array to get it
* working. Should be enough for all the
* usual tests so we can work on core
* functionality.
*
* TODO: change it to a linked list or
* something to dynamically track style
* tags.
*
* Update: Changed from 16 to 30 because Alex
* tossed in a new test that breaks this
* build. This really ought to be updated
* next major release, but for now we just
* need to get it working.
*/
- InclinedPlane 17y agoAvoiding these sorts of pitfalls is one of the greatest benefits to using a modern language with good generics support. In C#, for example, it's actually easier to code with lists than with arrays, so you can skip the "fix it so it doesn't have an arbitrary range limit" coding step (which often never gets done anyway).
- Malus 17y agoThe not-so-modern language that IE is written in (C++) has a similar construct (std::vector) in its standard library. It is possible that code was originally written prior to the widespread adoption of the STL and was never updated to use it.