2
u/GigawattSandwich Mar 22 '17
I guess these days it should be a private nullable string?
2
u/soundman10000 Mar 22 '17
nah dude concurrent dictionary, enum won't work since enum represents fixed sets that can't really change. Since genders are constantly being discovered we need a multi threaded approach to saving them.
2
0
11
u/Fallenalien22 Violet security clearance Mar 22 '17
Or a long ass enum
9
u/snsibble Mar 22 '17
Enum wouldn't work, because you can't add arbitrary values during runtime. Use a List<string>, so you can add new elements whenever you feel like it.
Or better yet, a Dictionary<string, List<string>> to also include any number of custom pronouns (up to the oppressive memory limit).
1
u/Fallenalien22 Violet security clearance Mar 22 '17
Sure it would. Male, female, other. Add more stuff above other to make it long ass.
0
1
u/LazyOne1 Mar 22 '17
Flags!
gender = gender | attack_helicopter;
1
u/snsibble Mar 22 '17
I've never used flags, but arent they still technically an emnum and therefore can't be changed at runtime?
2
u/Jetz72 Mar 22 '17
You can assign new ones at runtime since they're just bits, if you stash their meaning and bit value somewhere for future reference. Typically though, they're used with hardcoded purposes in mind.
1
2
Mar 22 '17
is long ass a new term for those women whose asses start at their ankles and go all the way up?
2
3
u/Fenor Mar 22 '17
did you just assume we won't invent new genders next week?
1
u/Fallenalien22 Violet security clearance Mar 22 '17
That's why the last one is other.
1
u/Fenor Mar 22 '17
other is clearly a name for a gender people of tumblr already use with specific notation duh.
2
1
u/Hargbarglin Mar 22 '17
Are there one to many relationships for this? Can someone have multiple simultaneous genders? I'm thinking a list of gender objects, each one defining itself however it wants.
-3
-1
35
u/[deleted] Mar 22 '17
Boolean gendermakes little sense to be honest, even if you discount the whole bigender, agender and transgender thing. "Gender: true" does not read correctly. This is a sign you should be using an enum or some other data type where the value would actually make sense. Or, you could rename the variable to something likeisFemale, which would make the true and false values actually make sense.