Skip to main content
7 events
when toggle format what by license comment
Dec 21, 2020 at 21:02 history edited Robert Harvey CC BY-SA 4.0
added 1 character in body
Jan 23, 2019 at 14:12 comment added Necromancer I don't create instances of my structs I access them directly wherever needed and I never see the need to use them as ref parameters.
Jan 22, 2019 at 22:42 history edited Martin Maat CC BY-SA 4.0
added 220 characters in body
Jan 22, 2019 at 22:35 comment added Martin Maat @Alexander We do not know if he has struct instances or not, for all we know he may create an instance and pass that Hero around as an argument to a method as a ref parameter. The struct itself is not declared static. I realize you are right with your first comment, I will edit.
Jan 22, 2019 at 22:24 comment added Alexander "You may even lose performance if you are not careful by cause boxing and unboxing." There's no boxing/unboxing going on, because there are no struct instances
Jan 22, 2019 at 22:23 comment added Alexander "Your struct will be 4 * 12 bytes in size" -> No it won't, because these are static fields.
Jan 22, 2019 at 22:20 history answered Martin Maat CC BY-SA 4.0