211 points · by wonderfuly · 7y ago · 176 comments
Here's the full list: https://developer.apple.com/documentation/contacts/contacts_...
A second issue is, this is probably a localisation / cultural concern: below, yorwba notes that this relationship is a specific term in chinese kinship: https://en.wikipedia.org/wiki/Chinese_kinship#Common_extende....
https://stackoverflow.com/questions/6163683/cycles-in-family...
Of course, this is kind of co-opting the call stack to build up at runtime what the compiler can already provide as an AST, so it might be better to just use a macro.
This representation can't be serialized quite as easily as a single symbol or whatever Apple is doing, but it is infinitely flexible. And it seems like a code smell to me that they have a special case for the father's brother, while the mother only has a generic "sibling." It should be up to the view layer to determine that kind of localization-specific logic. If you just store a completely arbitrary relation then you can punt it to the localization to decide how to translate that into meatspeak.
enum CNLabelContactRelation {
static let aunt = "…"
static let auntFathersBrothersWife = "…"
}English words like "aunt" cannot really be translated into Chinese. If you are translating a book you either try to figure out the exact relation from the context, or just pick one if it doesn't matter. In someones address book you can't do that.
The original English version had a passage where it was unclear (on purpose) which grandmother was being referred to (it later turned out to be the one you didn't expect). However, with Swedish having no generic word for grandmother (only mormor and farmor), this nuance was lost in the translation.
Elder sister of a girl
Elder brother of a girl
Elder sister of a boy
Elder brother of a boy
Younger sibling of whatever gender
So every time a "brother" or "sister" appears in English, a translator has to figure out their relative age, or make a wild guess.(Most of my learning is via Duolingo, so I'm no expert, just curious.)
It’s losing them fast though. Newer generations just don’t really care, so the words are falling out of use. I really only know cousin, aunt, uncle.
We do have quite a few words in Lithuanian (e.g. for maternal/paternal branches and more detailed words for "X in law"). But it was getting simplified in the past few decades. I've heard quite a few words that I couldn't describe without looking at the dictionary.
On the other hand, it has different words for "wife's mother" and "husband's mother", which in English are both "mother-in-law". Similar for the "father-in-law" relationship: different words for "wife's father" and "husband's father". Similar for sibling-in-law relationships.
(Of course there's the open question of whether Russian would count as "East" or "West".)
* Maternal/paternal parental siblings, with distinct terms for their respective spouses
* Maternal/paternal parental sibling - distinct terms if they are older or younger than your own parent
For aunts its faster/moster (portmanteau of father-sister, mother-sister, roughly). For uncles its farbror/morbror (lit. father-brother, mother-brother).
For grandparents its farfar/morfar (father-father, mother-father) and farmor/mormor (father-mother, mother-mother).
A great grandparent could be e.g. a farfarsfar, or father-fathers-father.
Ours is pretty simple, I imagine this system is intended to cover Chinese kinship which is _really_ complex. https://en.m.wikipedia.org/wiki/Chinese_kinship#Common_exten...
Coming from my native German, I am very much used to the former, so I always find it interesting to see how different other languages are structured sometimes.
English has long compound nouns too, by the way. You can make basically arbitrarily long nouns like "chief regional dairy inspector" in English. In German you would write this without spaces between the words. That's just a typographical convention, not a linguistic difference. It doesn't mean German's structure is fundamentally different from English's, and isn't what linguists mean by "agglutination".
Taking the 7th example from this table [1], while you could theoretically construct something like "erfolglosenmacherwerden" in German and have it still sound somewhat comprehensible, that is not something that is actively done in the usage of the language and would sound about as strange as coming up with "to unsuccessfulmakerbecome" in English.
[1] https://aimdanismanlik.files.wordpress.com/2012/04/539526_38...
Grandfather. Maternal grandfather. Paternal grandfather.
https://developer.apple.com/documentation/contacts/cnlabelco...
CNContactLabelRelation表姐
?I think it makes more sense to keep all identifiers in English or alternatively provide completely localized versions of the API in other languages, going halfway is just going to confuse everybody. Remember for instance the confusion created by PHP using hebrew in the symbol for the '::' operator: https://stackoverflow.com/questions/592322/php-expects-t-paa...
A middle ground might have been to use a transliteration such as CNContactLabelRelationBiaoJie.
Your point about input makes sense in that it's technically possible to type the English identifier without Chinese input methods, although I would be surprised if anybody typed that long-ass English identifier without IDE completion or copy-paste either!
The point about being able to more easily compare, I disagree with - the long identifiers are hard to check.
IMO if an API exposes an uncommonly-known but well-defined concept, I think it's acceptable, and better, to ask users of the API to learn the concept before use rather than paraphrase it.
It better matches what developers are likely going to try to do: if anyone is ever going to write a program that has to care about this case, I'm pretty sure the spec isn't going to be something like "if the contact is the user's elder female cousin who is either the user's mother's sibling's daughter or the user's father's sister's daughter..." - it's likely going to say, if not in Chinese, "if the contact is the user's 'biaojie'..."
There is good precedent for this kind of preference for expressing concepts that aren't broadly familiar in technical APIs. You'll get some symbols containing words like AffineTransform or CMYK in it, and probably many programmers wouldn't know what they stand for either until they need to learn what they are, but that's ok and better than dumbing down the API to something like RotationOrTranslationOrResizingOrCombinationThereOf or PrimarySubtractiveColorSystem.
I'm not sure it's easier with the super-large English name
Also, identifiers in Apple frameworks are always ASCII.
A Chinese person, an Apple engineer and a HN reader walk into a bikeshed...
e.g. the two Traditional Chinese characters 東京 translate roughly to "Eastern Capital" and are read dōngjīng, while they are also valid Japanese Kanji where they have the same meaning and are read as Tokyo. (Yes, the name of the capital of Japan.) Interestingly, Běijīng and Nánjīng similarly mean "northern" and "southern" capital respectively.
enum { h = 0, v = 1 };
This could lead to very confusing compiler errors... it was there for compatibility with an anonymous pascalnunion that let you treat a pascal Rect as an anonymous array of two Point structures..
https://developer.apple.com/documentation/contacts/cnlabelco...
This is my favorite topic.
Long story short, I started building against the newer SDK and the app started crashing in the most oblique way possible. Prefixing the entity and class name solved the problem, but I only stumbled on that through a combination of luck, intuition, and half a day of banging my head against a wall.
CoreLocation: CL (CLLocation)
SpriteKit: SK (SKScene)
CloudKit: CK (CKRecord)
CoreVideo: CV (CVBuffer)
LocalAuthentication: LA (LAContext)
So on and so forth...
(I know nothing about Chinese. Just reporting what's been said elsewhere.)
Or, for a more concrete example: "daughter-in-law". Many of the English "-in-law" relations may seem foreign to cultures with different conceptions of the extended family.
Because the Chinese kinship system has a specific term for the relationship described by this constant.
Your younger cousin sister, either from one of your mother's brothers and sisters, or from one of your father's sisters.
Or two characters in Chinese: 表妹(BiaoMei). If she is from one of your father's brothers, she's your 堂妹(TangMei). The latter is regarded as being closer because you share the same family name, but nowadays it just doesn't matter any more.
Some of the other commenters think it's 表姐. No matter who is right, you see, the long name bears no clear meaning even for Chinese.
This breaks the width of the page on mobile.
CN Label Contact Relation Elder Cousin Mothers Siblings Daughter Or Fathers Sisters Daughter
EDIT: HN strips zero-width spaces and replaces them with normal spaces, so I can't post it here.
Ok, I see it now: there are wbr tags between the words on the page. TIL.
* in many EA and SEA culture, there's a difference made based on the age differential aka different term of address to people older than you v younger than you, also gender
* chinese (and likely others) also make a difference between patrilineal relationships and matrilineal, so there's a term of address for people related through the father's brother (and thus sharing your family name) versus other parent's sibling (not sharing your family name).
The combination of the two yields what you have above:
* cousins through your father's brother (sharing family name) are 堂 (táng) all others are 表 (biǎo)
* older brother is 兄 (xiōng), younger brother is 弟 (dì), elder sister is 姊 (zǐ) and younger sister is 妹 (mèi)
Therefore an older "sister" (same generational rank) through an other line than your father brothers would be 表姊 (biǎozǐ).
> InternalFrameInternalFrameTitlePaneInternalFrameTitlePaneMaximizeButtonWindowNotFocusedState
Thankfully, I think they fixed it in the newer version.
[1]: https://twitter.com/peterlawrey/status/577176384520384512
Still easier to understand than this monstrosity, even for those who don’t speak Chinese (assuming they can google the documentation).
Something like CNBiaoJie also assumes that Chinese is the only language that names this relationship, and I don't know if that's true.
Also curious as to why this is important enough to have a specific type of contact for?
tr.athing td.title:not([valign="top"]) {
word-break: break-word;
}
[1]: https://github.com/plibither8/refined-hacker-newsDataGridViewColumnDividerDoubleClickEventArgs
ListViewVirtualItemsSelectionRangeChangedEventHandler
https://github.com/mattl/opensource.apple.com/blob/88cbaab4a...
Edit: ok, thanks to https://en.wikipedia.org/wiki/Unicode_character_property#Whi... I put in a bunch of ​. I hope that fixes it because I need to sign off now. If it isn't fixed, it would be helpful if someone would email hn@ycombinator.com so we see that in the morning. Short term memory does not survive the firehose.
1: https://de.m.wikipedia.org/wiki/Rindfleischetikettierungs%C3... - check out the voice version!
I was wondering what was going on there.