← Back to context

Comment by andy_ppp

1 day ago

So you’d advocate that codebases should be written in the locale of the people writing them? What about open source projects, should they be dictated by the first language of the creator in most cases?

You presumably can’t use British English for the standard library calls so now you have a mixture of languages which to me is pointless and more about the ego of the people writing things. I’m just in favour of consistency which unfortunately you cannot achieve unless you’re wrapping americanised standard library calls with true English equivalents.

If you were coming to a codebase that defined American English as the standard I’m certain you wouldn’t change it. Why then when the underlying language makes that choice for you do you feel good about ignoring that?

"So you’d advocate that codebases should be written in the locale of the people writing them?"

That's unavoidable, to some degree. You can be a programmer who doesn't speak English particularly well. You can write code about a domain that lacks English terms (e.g. you're writing code for a government in Norway — there will be words in your code that lack English equivalents).

Why should a team in China spell out everything in English if very few (if any) English speakers will ever see that code, and if a lot of the people on the team don't speak English well? Just because the language has keywords like "if" or "function"?

Why would you assume that the open source project in question would be written in US english?

Hell, why assume that the project even be written in english at all? There's more non-english speakers in the world than english speakers

  • Because if you want your project to be well used and contributed to you’re probably writing it in English. I don’t see too many French or Arabic or Chinese or British English open source projects that have taken off, but I’m happy to be proven wrong…

    Even large open source projects built in China like Ant Design have documentation and interfaces in American English because even if you don’t like it it’s the correct decision to not needlessly buck against patterns laid down in the programming environment you’re working in.

TBH most programming languages' alleged "English" is their own weird dialect anyway. Take Ruby's "include?" (should be includes?, and yes I have read the rationale), for example, or the eternal weirdness that is C++ ("deque" ain't no country I've ever heard of). If you're going to fixate on doing the same as the stdlib then you're just laying down rakes in your own path.

The belief that only the US'ian way of doing things is correct is curiously prevalent on the other side of the pond to a level that borders on arrogance.

  • All I’m saying is keep your codebase consistent with the language the standard library of the coding language you’re using. If there was a programming language with British spelling without the use of awful hacks I’d be fine with that. Unfortunately most languages use American English, deviation from this means mixing languages and debate, therefore I’d consider it bad practice in almost every case.

> So you’d advocate that codebases should be written in the locale of the people writing them? What about open source projects, should they be dictated by the first language of the creator in most cases?

Yes. I'm the one writing the code and I can use whatever bloody spelling I damn well prefer. If someone else takes over then they're writing the code and they can use whatever spelling they want.

Trying to enforce some particular detail like spelling or whatnot for all of "open source" is just eyerolling. Use what you prefer and leave the rest alone. It's that simple.