Absolute fastest (and hopefully elegant) way to return a certain char buffer given a struct type
问题 OK first and foremost, performance is most important here so I doubt a map would work. I have a list of structs (about 16 of them) like struct A { ... }; struct B { ... }; ... each are different and each are of different sizes. I'm wondering what elegant way we might be able to do something along the lines of: char BufferA[sizeof(struct A)]; char BufferB[sizeof(struct B)]; then write some method or mapping to return BufferA if you are working with struct A. Speed is definitely the most