[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MiNT] Programming style



 
When I implemented the deadkey-stuff in keyboard.c, I noticed that there were no static variables inside functions. Global variables are used even for variables that are used inside a single function, I would say that a local static variable would be better for this. So before I submit my patch - must I move the local static variable out of the function, or is this OK?
It's very well possible those global / outside static variables are there for historical evolution, i.e. in the past there was more functions which used that and now it's not true anymore... or the programmer was not so skilled to know about something like static variables :) I see no single reason why not to refactor the code to some better shape.


--
MiKRO / Mystic Bytes
http://mikro.atari.org