Interesting... I can almost imagine where you would use this, but not really... Is there a restriction on what you can put in a Union? Could I put things like UITableViewController or UIImage or just scalar?
@randomblink To be honest I have never tried. It really wouldn't be helping much (if it did work) I don't think because you would only have 2 pointers, you wouldn't actually be allocating the memory for each object in the union. So I would say in theory yes, but I doubt it would be useful.
Interesting... I can almost imagine where you would use this, but not really... Is there a restriction on what you can put in a Union? Could I put things like UITableViewController or UIImage or just scalar?
randomblink 7 months ago
@randomblink To be honest I have never tried. It really wouldn't be helping much (if it did work) I don't think because you would only have 2 pointers, you wouldn't actually be allocating the memory for each object in the union. So I would say in theory yes, but I doubt it would be useful.
AppleProgramming 7 months ago