Catch up on stories from the past week (and beyond) at the Slashdot story archive

 



Forgot your password?
typodupeerror
×
Java Open Source IT

OpenJDK Bug Report Complains Source Code 'Has Too Many Swear Words' (java.net) 281

Thursday a bug report complained that the source code for OpenJDK, the free and open-source implementation of Java, "has too many swear words." An anonymous reader writes: "There are many instances of swear words inside OpenJDK jdk/jdk source, scattered all over the place," reads the bug report. "As OpenJDK is used in a professional context, it seems inappropriate to leave these 12 instances in there, so here's a changeset to remove them."
IBM software developer (and OpenJDK team member and contributor) Adam Farley responded that "after discussion with the community, three determinations were reached":
  • "Damn" and "Crap" are not swear words.
  • Three of the four f-bombs are located in jszip.js, which should be corrected upstream (will follow up).
  • The f-bomb in BitArray.java, as well as the rude typo in SoftChannel.java, *are* swear words and should be removed to resolve this work item.

He promised a new webrev would be uploaded to reflect these determinations, and the bug has been marked as "resolved."


This discussion has been archived. No new comments can be posted.

OpenJDK Bug Report Complains Source Code 'Has Too Many Swear Words'

Comments Filter:
  • by Geoffrey.landis ( 926948 ) on Saturday December 15, 2018 @10:37AM (#57808182) Homepage

    That's a pretty wide definition of "bug".
    I'd think that maybe they could devote their debugging efforts to more annoying bugs...

    • by SirSlud ( 67381 )

      You would think you have better things to do, like eat, drink, work, sleep than comment on a /. story.

      Actually not too many people would think that because they'd recognize that we can do lots of things. In your code bases, do minor and easy to address bugs never get addressed on the basis that there 'should be more important bugs'? See how stupid that sounds?

    • If someone went on a tirade cussing out the developers for the occasional profanity, and demanding everyone else change their behavior, I would tell them to fuck off. From what I can tell, they do didn't have a freak out, they just did a pull request to clean things up.

      > I'd think that maybe they could devote their debugging efforts to more annoying bugs...

      While I don't disagree, I also note that their work is slightly more useful than what you and I contributed to OpenJDK.

      If this person wants to remove

    • But now the committer can put on their resume "Committed code to OpenJDK."
    • debugging efforts

      If running grep to find some swear words is your definition of "effort" then you have no business commenting on how someone manages code.

  • Yeah ... (Score:2, Insightful)

    by cpurdy ( 4838085 )
    Fuck this shit ...
  • let the programmers & community decide by up-voting this if they care.
  • by gweihir ( 88907 ) on Saturday December 15, 2018 @10:45AM (#57808216)

    Obviously, we are moving more towards NewSpeak. It seems nobody reads the classics anymore and the same evil mistakes are getting prevalent again.

    • Don't you mean the same doubleplusungood mistakes?
    • by dryeo ( 100693 )

      Well what should we do about the religious snowflakes? Perhaps get rid of freedom of religion and as someone above suggested, murder all the religious right wing nut jobs that are so easily offended by body parts and natural things like sex?

      • Well what should we do about the religious snowflakes? Perhaps get rid of freedom of religion and as someone above suggested, murder all the religious right wing nut jobs that are so easily offended by body parts and natural things like sex?

        That's funny - the people asking to silence me aren't from the right. The people actually succeeding in silencing others also aren't from the right.

    • Re: (Score:3, Insightful)

      by AmiMoJo ( 196126 )

      While I personally don't five a flying fuck about swearing in source code and can't really see how it could be an issue when using the JDK in a "professional" environment, you are massively over-reacting.

      If the source contained stuff like personal attacks, doxing, or giant ASCII penises that stuff would probably be removed for what are hopefully obvious reasons. So clearly there are already some standards in place that have been widely enforced for as long as modern English has existed, and didn't cause any

      • by AHuxley ( 892839 )
        Should a "professional" environment want good code they can pay for that their own clean code.
        Using their own staff. Hire staff to write code for them that is "professional".
        Why should anyone have to worry about their code been '"professional" and what "environment" then later selects to use that code.
        Who gets to set the SJW standards? The people who work on the code every day?
        A '"professional" who later wants to use that code?
        • by AmiMoJo ( 196126 )

          Linux has benefitted immensely from commercial contributions. In fact the majority of work is now done by people being paid to do it. I don't know about JDK but it seems similar.

          Seems that for the sake of retaining a few swear words out of the source that could be a big loss.

          As to who decides, I guess it's the same SJWs who decided you masturbate in public, i.e. fascists.

  • by Anonymous Coward on Saturday December 15, 2018 @10:45AM (#57808218)

    I can see the one for this ticket now:

    "Updated comments to remove 'fuck' 'shit' and 'bollocks' as some millenial wanker decided to complain. Pussy."

  • by Anonymous Coward on Saturday December 15, 2018 @10:45AM (#57808220)
    One of my favourite code comments came from a French Canadian coder in a shutdown routine for a Unix daemon process that spawned a lot of child processes where he wrote: "And now we kill all the children...".
    • by Kjella ( 173770 )

      One of my favourite code comments came from a French Canadian coder in a shutdown routine for a Unix daemon process that spawned a lot of child processes where he wrote: "And now we kill all the children...".

      It's all well and fun until you hit the wrong person. I remember reading a story, it might have been on the daily WTF but I couldn't find it about a guy who called up a coworker about a "child killed" problem. There was just a *click* then no answer... a colleague filled him in, the other type of "child killed" just recently. Ouch.

  • Mental note: Next utility I don't want to make will be entirely constructed using profanity.

    Just need to work out the style guide for it now, high level is open to discussion.
  • Heat (Score:5, Interesting)

    by JBMcB ( 73720 ) on Saturday December 15, 2018 @10:47AM (#57808236)

    I've seen very select cases where swearing in comments can be useful.

    There was a piece of code I saw that people thought was a bug, but was actually purposefully written a particular way to get around a bug in the compiler. Even after comments like // SERIOUSLY do not touch this it's a workaround for CVXXXXXX

    People kept messing with it. Finally the dev checked in // DO NOT F****ING TOUCH THIS

    and the regressions went away. Again, niche applications, but still valid.

    • by SuperKendall ( 25149 ) on Saturday December 15, 2018 @11:39AM (#57808500)

      People kept messing with it. Finally the dev checked in // DO NOT F****ING TOUCH THIS - and the regressions went away.

      This is exactly why you should really try not to swear, in writing or in speech...

      It's because it cheapens the words, and they loose effect.

      These days if someone called you a motherfucker, it's kind of like calling you annoying. It has no power.

      The reason that comment kept people away is because swearing in code is still relatively uncommon, so it has power. So keep the F-bombs out of code, so when the time comes where it is needed, it still works.

      • I think they should be evaluated on a case by case basis. If for some reason the devs on a project keep messing with the magic number assigned to a file type, a well placed comment cussing them out to prevent that behavior is probably called for. Cussing someone out for a dumb mistake in the code is probably not warranted and should be reverted.

    • by jd ( 1658 )

      Badly designed code, comment and corrective action.

      Good code should have contracts that prevent breakage from (ideally) compiling or, at worst, passing absolutely any of the tests in the test harness you've got rigged to run on code checked in to the repository.

      Good comments should explain what is done, not simply justify it. Code reviews should validate that future changes to the code do not invalidate the description.

      The corrective action for checking in broken code, regardless of the nature of the breaka

    • by AmiMoJo ( 196126 )

      I always thought the "increase this counter every time you try to improve this and fail" comment was more effective for keeping people away from tricky code. I normally start at 7.

    • by c ( 8461 )

      I've used some pretty harsh language in the context of compiler bugs.

      Spending days to discover that adding "assert(sizeof(char)==1);" is needed to force sizeof(char) to be 1 is worthy of a good cathartic vent, IMHO.

  • by SchroedingersCat ( 583063 ) on Saturday December 15, 2018 @10:57AM (#57808298)
    As if removing the words will make that monstrous ball of crap better.
  • by ameline ( 771895 ) <ian.ameline@gma i l .com> on Saturday December 15, 2018 @11:05AM (#57808336) Homepage Journal

    Perhaps it might be a good idea to figure out (and fix) the underlying reasons prompting developers to swear in comments.

    As an aside, One late evening, I once constructed an sql query to look for a variety of swear words in the bug database used at Alias (before Autodesk bought us) -- Amon several, one stood out. It was originally opened by a customer (working in New Zealand on some small films made there -- something about a ring or whatever). It was epic in its use of invective. It tore a strip off of the software and the cretins who had written it (myself included, but not specifically named). The author had been hired and was working at Alias at the time of my query (this was a few years later) (Hi Dave :-) ). We had some fun passing the link to the bug report around.

    • Perhaps it might be a good idea to figure out (and fix) the underlying reasons prompting developers to swear in comments.

      And sometimes the underlying reasons are dictated by product management. Like the ridiculous feature they required a whole alternative firmware build for. Ah, such fond memories of #ifdef CLUSTERFUCK.

  • by Alain Williams ( 2972 ) <addw@phcomp.co.uk> on Saturday December 15, 2018 @11:11AM (#57808374) Homepage

    is someone now going to waste their time checking for variable names, words in comments, ... that just happen to be a swear word in French, German, ... and by transliteration Hindi, Chinese, ... ?

    • by Bite The Pillow ( 3087109 ) on Saturday December 15, 2018 @01:38PM (#57809010)

      No.

      Unless you submit a bug report to do so, which will be closed as not enough information, so still no.

      I bet you were proud of this comment. Stop it. You're not helping.

    • by AmiMoJo ( 196126 )

      Does Chinese even have swear words? Japanese doesn't, not really. Even on kids shows they say things like "kuso" (shit) because it's seen as impolite but the concept of "words that simply should not be uttered even though they mean the same as other words that are impolite but not swear words" doesn't exist.

      • 'Du leah lo mo' means 'hello old friend'. Say it to your Chinese associates and coworkers.

        That Chinese has no swear words in an oft repeated lie.

  • When you self proclaim to be virtuous (ie open source is more cirtuous than proprietary) you will eventually attract people who consider themselves to be virtuous. This is a consequence of that.
    • by djinn6 ( 1868030 )

      Free software is actually not as virtuous in the political and moral sense. Businesses can be pressured to stop servicing bad people, but free software can be used by everyone.

  • Does this reporter have any evidence of people using the source of OpenJDK and being somehow unable to cope with the comments or otherwise having problems because of the language?

    It sounds to me like he's making shit up.

    • Does this reporter have any evidence of people using the source of OpenJDK and being somehow unable to cope with the comments or otherwise having problems because of the language?

      It sounds to me like he's making shit up.

      It's not about being "unable to cope".

      All words are just arbitrary sounds that convey meaning. So what? Part of the meaning that offensive words convey is offensive meaning. They are literally intended to give offense; that's their meaning. Which is not appropriate in professional settings.

      There's nothing superior about not knowing or caring (or pretending not to know or care) about the meanings of words.

  • What is the sufficient amount?

    Here's a tip: do something about something that matters and stick your moronic childish worries about some words up your ass.

  • One of our developers used a couple of very off color limericks as static strings to test some of his functions in our string utilities library. Well, he forgot to take it out before committing them, and it ended up in code, and some customer ran strings on it ...

    Another developer left in ShowError("Fuck! Got null again!",true/*=fatal*/) in shipping code.

    Another one had a long rant denouncing Osama Bin Laden as a static string, unused but visible in strings.

    It happens a lot.

  • In my opinion, there aren't enough.

  • ..or code submitted, feel free to provide "better" submissions with cleaner code or cleaner comments and if people like your version better, it gets in. This is Open Source, no one should be allowed to push out content (incl comments) the project agrees is good without providing a superior submission. Besides this criticism totally ignores the possibility that the thing being described was not so bad that profanity was the most accurate description.

  • If these snow flakes are that sensitive for perceived insults, I demand all references to "problem" to be removed from OpenJDK. See "problem" translates to my native language as "sknt", which is written as "sikinti" when ASCII used. "Sikinti" in turn can be used in several different contexts those are related to "dick", "fuck" and "fucking". OTOH I am afraid we can actually find some morons who would take my complaint above seriously and try to "correct" this issue. My apologies in advance for any inconven
  • Mark Twain had to trash the first print run of Huckleberry Finn because an engraver made a subtle pornographic change in an illustration. I doubt he cared whether this off-color joke was ever meant to become public --- as an editor and publisher he had to answer for it. Think about who will be reading your comments and whether they are actually useful.
  • For religious reasons I insist source code contains a significant amount of blasphemy. Time to open a bug.

  • It doesn't meet the original design criteria, it's unclear it meets the current one either, it's abysmally slow, it encourages bad programming and it causes profuse profanities.

    So it's still better than C#, but really isn't fit for any kind of professional setting.

  • In my experience, swears in comments are like swears in real life - usually 90% of the f-bombs in a given group are one or two people. It's not that the other people are so prim and proper that they won't swear, it's that they only swear when it's called for. But there'll be that one person who has to whip out fuck for as an adjective for every minor ailment in their life.

    [Of course, it's different in groups where 90% of the sentences spoken contain a swear word. I haven't often been in such groups since

  • Adam Farley is a fucking snowflake and has no sense of humor :]
  • by dos1 ( 2950945 ) on Saturday December 15, 2018 @11:04PM (#57811040)

    This is such a non-news. There wasn't even any controversy inside the project. Just a patch, short discussion, resolution, like many others that happen in many different projects each day. How is this newsworthy in any way?

  • ..NOT XKCD.

    WTF/m [osnews.com]

  • by Tom ( 822 )

    I've written tens a couple hundred thousand lines of code in my life.

    Sometimes, "fuck" is the exact word that expresses things correctly, precisely and honestly. Didn't they teach you in CS class to write good documentation? There's stuff out there that cannot be captured any more perfect than writing "fuck".

    I'm all for maturity and professionalism. And when I get a piece of code from someone else and I need to fix it or maintain it or extend it, I don't want it white-washed to conform to someones idea of p

  • Even if "crap" and "damn" are not swear words, I fail to imagine a situation where they are appropriate in a comment or a variable name (unless you are building a bad language filter, of course).

If you have a procedure with 10 parameters, you probably missed some.

Working...