If a translation page has a link to its translatable page made via Special:MyLanguage/ and the interface language matches its contentlanguage (in other words this is the same page you will happen to be after following the link) the link should be rendered not as a link but as a class="selflink" piece of text.
Description
Related Objects
Event Timeline
This is not possible to do without breaking the parser cache for the page by language.
I do not have data to know how frequently that is already happening and what is the impact.
Reposting my comment from T301530:
The current interface language, the preferences interface language, and the page language cannot be assumed to be connected. The purpose of redirecting special pages is that the target isn't known at parse time. Additionally, if implemented, this would fragment the cache even more than Translate already does. I suggest closing this task as declined.
I disagree, you can just assume links via MyLanguage from a page that it *could* redirect to depending on interface language to be self links, that would be imperfect, but better than what it is now.
Parsoid tries to do more of the red link processing in post processing; this could be done in a post processing pass without breaking parser cache.
The parser cache is there to minimize the amount of post-cache transforming, wouldn’t this approach be counterproductive? Unlike red links, the self link state cannot change due to external changes, so we wouldn’t have to invalidate cache entries just because of this. And I think “breaking parser cache” would in this case simply mean that pages appear inconsistently until the old cache entries expire; if this temporary inconsistency is acceptable (I think so), no backward- or forward-compat code is needed.