91
submitted 1 week ago* (last edited 1 week ago) by NONE_dc@lemmy.world to c/asklemmy@lemmy.ml

I ask because sometimes I feel very silly when writing clumsily in English and even sillier when I have to look up how to spell a particular word.

I want to know if I'm the only idiot that it happens to or if on the contrary it's something generalized.

(Mi idioma es el Español, por cierto)

all 48 comments
sorted by: hot top controversial new old
[-] BlessedDog@lemmy.world 37 points 1 week ago

This is interesting, I've thought of this before.

I write comments and commit messages in English, mainly because programming is collaborative. I am a member of a local association of young programmers, and in the community (discord, meetups) we speak Finnish, however all interactions on github are in English, so are function and variable names, as well as comments. If someone makes a PR and it's reviewed, it happens in English, even if both parties are native Finns.

[-] i_stole_ur_taco@lemmy.ca 28 points 1 week ago

This is expected Canadian source code:

// cache the colour in case we need it later for the neighbour
color = fetchColor();
neighbor.color = color;

When language keywords are all written in American English it’s foolish to try to author your code in a different language. But comments are fair game.

[-] PoolloverNathan@programming.dev 3 points 1 week ago

Do those rules change if the language accepts translated keywords?

[-] Dirk@lemmy.ml 22 points 1 week ago

German here.

I am not writing anything in my code in German. All of my code, my variables, my default texts, my comments, my documentation, my UI strings, etc. are always and explicitly in English.

The only German I use, is when I provide translations for UI or documentation.

[-] nutbutter@discuss.tchncs.de 20 points 1 week ago

I don't write a lot of codes, but when I do, it is usually a mixture of broken English and my native language.

[-] NONE_dc@lemmy.world 9 points 1 week ago

You're one of mine 🤜🤛

[-] 0_0j@lemmy.world 3 points 1 week ago

You best backup your strength, cause you'll need them to explain to young'uns what you meant when your 90 Years old

[-] ReeSilva@bolha.forum 18 points 1 week ago

I write in the official communication language of the company, because that's guaranteed that everyone that will be hired will have to speak that language. I came from Brazil and it is a massive country and most of the population doesn't have access to good English courses, so I like to go with the easiest solution for all future joiners

[-] dsilverz@thelemmy.club 5 points 1 week ago

I'm not sure if it's a São Paulo (as in the state, not the city) thing, but I had English classes when I was in public high school ("ensino médio"). They weren't the best English courses out there (i.e. they weren't comparable to Brazilian schools that specialize in English courses such as CCAA, CNA, Fisk and Wizard), but they offered a good start for those who had no prior knowledge of the English language. It's also worth mentioning that people who work in IT have more potential to come into contact with communication in English because a lot of documentation is in English. But I totally agree with you that most of the population does not have quality access to English courses.

[-] kubok@fedia.io 15 points 1 week ago

Always English. I live in a country where developers are hard to find. Chances are that I will get colleagues who do not speak my native language (yet).

[-] folkrav@lemmy.ca 14 points 1 week ago

I’m French speaking, but I write all code and comments in English, all the time. The code is basically English keywords and symbols, the mix and match just looks weird, makes it harder to share snippets for help or debugging with non-speakers. Especially in code that will be read by other people after the fact, it also tends to make it less likely that this person will be able to understand it - maybe they’ll hire an offshore team or some guy who just immigrated…

[-] xmunk@sh.itjust.works 13 points 1 week ago

Bold of you to assume I write comments.

(Yes, they're usually in my native tongue. I think it's better for you to express your comment clearly then stumble through a different language to make it accessible... chances are you'll be reading that comment next and non-spanish speakers can use Google translate or whatever and ask you if something is unclear).

[-] folkrav@lemmy.ca 3 points 1 week ago* (last edited 1 week ago)

The place I used to work at had a bunch of people speaking various South and North Indian languages, Vietnamese, Swedish, French, English, Spanish and Brazilian Portuguese. I’d have spent my whole days on Google Translate lol

[-] algernon@lemmy.ml 10 points 1 week ago

If I'm working for someone else (company or otherwise), I'll write comments and docs in whatever language I can speak that they want me to (which pretty much means I write comments in English, because I rarely work for Hungarian companies nowadays, and even the ones I did work for preferred English, and these are the only two human languages I can write :().

When working on my own projects, it is always English, because Hungarian doesn't have good translations for many of the technical terms, so half my comments would be English borrowed words anyway. Might aswell write the rest in English too. Also makes it easier for others to chime in, because there are a whole lot more people speaking English than Hungarian.

It was harder in the beginning, when my command of the English language was far worse, but even then, half-Hungarian/Half-English comments just looked weird, and more jarring than full English, even if that English was kinda bad.

[-] aluminium@lemmy.world 10 points 1 week ago

No, I once had the displeasure of working with a mixed german english codebase (where also classes and functions were in both languages). It was quite the experience.

[-] edinbruh@feddit.it 9 points 1 week ago

Depends. Generally English, unless they are "directed" to one specific person like the professor who's gonna grade it. But even then I might go with English anyway.

Oh I also use my language when I'm leaving an important warning to myself in a config file, like "this is needed because X! don't touch it! If you touch it do Y!"

[-] sag@lemm.ee 9 points 1 week ago

No, It will look so wierd.

[-] 0_0j@lemmy.world 4 points 1 week ago* (last edited 1 week ago)

Exactly. In case you haven't noticed, English is defacto communication language in most paradigms, especially in the programming domain.

Even broken English passes as English nonetheless

[-] dsilverz@thelemmy.club 9 points 1 week ago

I'm Brazilian. For personal projects and snippets, especially if I'm going to share their code publicly (e.g. GitHub or GitHub Gists), I often use English. However, when it's a project from a company I'm working for, I use Portuguese, as every company I've worked for so far are Brazilian (and my coworkers were Brazilian as well).

[-] daggermoon@lemmy.world 9 points 1 week ago

They should all be written in Esperanto.

[-] NONE_dc@lemmy.world 3 points 1 week ago
[-] Noodle07@lemmy.world 2 points 1 week ago

Mi konsentas

[-] leisesprecher@feddit.org 8 points 1 week ago

That depends, actually.

In general, I try to keep everything English, since we do have some international colleagues.

However, I work with a bunch of projects that have some legal/administrative background and certain words have very precisely defined meanings, that can't be easily translated (at least not in one word, so that the next guy can back-translate the word). So in these cases, I sometimes write comments that explain the domain problem in German, because it's much much easier and whoever touches that code better understand the German terms or screw everything up. Unfortunately class and method names are often a weird language mix.

It's not a perfect solution, but given the legal complexities behind seemingly simple words, it's the best of the worst.

[-] gentooer@programming.dev 1 points 1 week ago

That's an interesting perspective. Do you think it would be better to have separate legal documentation in German, which you then can refer to in your comments?

[-] leisesprecher@feddit.org 1 points 1 week ago

That would be a way to get rid of German comments, sure. But it's also another layer of hassle. Usually, the comments are just a few lines to explain weird behavior.

The naming problem is nearly unsolvable, though. Unless you want to map every concept to a random string, but that's not feasible either.

[-] superkret@feddit.org 8 points 1 week ago

Comments are in English, but output is in German because I only write for myself, my OS has German localization, and English output would look out of place.

[-] oktoberpaard@feddit.nl 7 points 1 week ago

Using English is the only way that all my colleagues are able to read it, but if it’s just meant for you, or only for Spanish speaking people, I’d say why not.

[-] MicrowavedTea@infosec.pub 6 points 1 week ago

In English even when I'm the only person working on the project as there's always the prospect of someone else looking at it. Also my language doesn't use the latin script and I don't want to mix other scripts into code files. You can always write it in latin script but that's really annoying to read. Funnily enough I wouldn't be so against comments in another "big" language like Spanish or German.

[-] GissaMittJobb@lemmy.ml 6 points 1 week ago

I've always been writing comments and using variable names in English, at all jobs I've had. Probably also the non-professional code before I started writing code professionally.

Part of this is that I've been working in a lot of companies with non-Swedish speakers, and another part is that it's just kind of been expected that the code and everything around it is in English.

[-] Boomkop3@reddthat.com 5 points 1 week ago

Oh heck no, that would be horrid. Why would anyone willingly mix three languages for the sake of less readability and frustrating the heck out of most other devs?

[-] telepresence@discuss.tchncs.de 5 points 1 week ago
[-] crypto@sh.itjust.works 5 points 1 week ago

I code in English by habit, comments included. I sometines write comments in French when writing code just for me, but code I write that is meant to be used by others is in English.

[-] Treczoks@lemmy.world 4 points 1 week ago

This actually depends on the kind of project. In larger and longterm projects I write my comments in English. In quick jobs like writing a source code generator or data swabbler that I need once or relatively short term, I use German. It does not make much of a difference for me, though, and I have a script that walks over a source tree to find some common German words just in case I had written something in German by accident.

[-] Matriks404@lemmy.world 3 points 1 week ago* (last edited 1 week ago)

Writing detailed and technical comments in English is easier that saying a simple English sentence in real life for me, lol.

[-] anotherhoffmann@feddit.org 3 points 1 week ago

I try to write them in English, but some German ones get through, when I am in a hurry or talking to a colleague (in german).

[-] nichtburningturtle@feddit.org 3 points 1 week ago

I do write them in English for personal projects. On everything else it depends on the requirements of the project.

[-] cralder@lemmy.world 3 points 1 week ago

At my job we write everything in english. Code comments, variable names, review comments. Everything. It's just to make everything readable to people who don't know our language because some people in the office are from other countries.

[-] gilgameth@lemmy.world 3 points 1 week ago

My language is rtl, so... shit no!

[-] schnurrito@discuss.tchncs.de 3 points 1 week ago

depends on what everyone else on the project is doing

[-] frigidaphelion@lemmy.world 2 points 1 week ago

...why is this nsfw exactly?

[-] NONE_dc@lemmy.world 1 points 1 week ago

I don't know what are you talking about. I didn't mark the post as nsfw and when I try to modify it, the nsfw option is disabled.

[-] frigidaphelion@lemmy.world 1 points 1 week ago

Must be something weird on voyager or just my phone then, apologies

[-] hostops@sh.itjust.works 2 points 1 week ago

Yes of course. For collaboration with current and future remote abroad workers. Also in my country almost everyone speaks English.

[-] Braindead@programming.dev 2 points 1 week ago* (last edited 1 week ago)

I'm not a native English speaker, current country is non-English as well (ahora es español) . My comments have always been in English.
I review and deal with a lot of code from different countries, and it's always annoying if I have to throw the comments through a translator, if I think I'm not understanding the comment well enough.

[-] eatham@aussie.zone 1 points 1 week ago

I only know how to write English, but if I knew writing in multiple languages I would write the comment in both languages

[-] 0_0j@lemmy.world 2 points 1 week ago

We should definitely make a plugin that will translate English comments into any language

this post was submitted on 20 Oct 2024
91 points (98.9% liked)

Asklemmy

43733 readers
1444 users here now

A loosely moderated place to ask open-ended questions

Search asklemmy 🔍

If your post meets the following criteria, it's welcome here!

  1. Open-ended question
  2. Not offensive: at this point, we do not have the bandwidth to moderate overtly political discussions. Assume best intent and be excellent to each other.
  3. Not regarding using or support for Lemmy: context, see the list of support communities and tools for finding communities below
  4. Not ad nauseam inducing: please make sure it is a question that would be new to most members
  5. An actual topic of discussion

Looking for support?

Looking for a community?

~Icon~ ~by~ ~@Double_A@discuss.tchncs.de~

founded 5 years ago
MODERATORS