The order does matter and that is why I had the strange sort in there, because it didn't sweep the stuff, thanks for the helpful suggestions, I felt like I was being attacked though. I used a hash and because I intended to use the module with a Tk widget to make the module useful in VT52/VT100 emulation.
Update: I reposted my text on this node.