Re: [AD] Proposal for new branch

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


Yes. A lot of the duplicated code should be merged together eventually.

vtables introduce overhead and are annoying (for reading, writing, experimenting, debugging...), so I didn't want to use them unnecessarily. But we can return to them later, if desired.

The overhead is just some pushes and a call instructions... not much a loss on modern CPUs. I know they can be annoying for debugging, but the advantages are 1) no code duplication and 2) fewer possibilities to have a port behaving differently from another one. As a consequence of 1), the lib code also becomes easier to read and maintain IMO. About readability, can you stick with the old habit of writing a small header for each function, telling what the function does? With so much new code (and expecially since you now have userland functions spread both on the core source dir and the platform specific dirs, instead of just on the code dir) it's hard for newcomers to get what's really going on...

--
Angelo Mottola
a.mottola@xxxxxxxxxx
http://www.ecplusplus.com





Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/