To be honest, I think you’re wrong with your approach here, and have prematurely optimized in what are probably the wrong ways in some places.
-
Like you said, this is partially a legacy code thing. Under the old Lua VM, there’s no question that using arrays of fields like that was better. But that’s not the case anymore.
-
If you have a bunch of very small objects where you need to squeeze that kind of memory difference out of them, using arrays of fields isn’t the answer anyways, using a Structure of Arrays instead of an Array of Structures is.
-
“There’s something very satisfying about compiling a project and having unneeded information like field names stripped.” – I mean, you’re free to think that, but I don’t think it’s a good idea development process wise. You haven’t given any argument as to why you think other people should also be doing that, simply that you personally like it.