DEV Community

Cover image for Epic code comments

Epic code comments

Nelson on October 25, 2017

I know my lack of expertise never play for me but as someone who is trying (very hard) to learn how to code, one of my exercise I tend to do is to ...
Collapse
 
ben profile image
Ben Halpern

This is making me feel like my personal website is lacking in this area.

Collapse
 
rhymes profile image
rhymes

your website started my computer's fan, I basically never hear the fan. your website is evil ahhaha :D

Collapse
 
nrobinson2000 profile image
Nathan Robinson

Why is your website so horrendous?

Collapse
 
ben profile image
Ben Halpern • Edited

Collapse
 
nektro profile image
Meghan (she/her)

and no https too?

Collapse
 
maestromac profile image
Mac Siri

Hahaha, that is a nice find. I'm only aware of facebook's warning but I am now motivated to keep the devTool opened at all time.

Collapse
 
nelruk profile image
Nelson

LOL. I never checked and it's translated :) This is cool

Collapse
 
maestromac profile image
Mac Siri

translated!? picture please

Thread Thread
 
nelruk profile image
Nelson

4 real
Look

Thread Thread
 
maestromac profile image
Mac Siri

Love it

Collapse
 
sabatesduran profile image
Dídac

SoundCloud offering for jobs:
SoundCloud console

Collapse
 
amanjeev profile image
Amanjeev Sethi

Maybe y'all already know this but Stackoverflow has some good ones on one of their Q/A stackoverflow.com/questions/184618...

Comments like

// sometimes I believe compiler ignores all my comments

Collapse
 
nelruk profile image
Nelson

I'm so happy with little stuff. Made my day sir

Collapse
 
etcwilde profile image
Evan Wilde

Straight from the Linux kernel;

    /*
     * IOC3 is fucking fucked beyond belief ...  Don't even give the
     * generic PCI code a chance to look at the wrong register.
     */

It's great because there are a bunch of labels and gotos for oh_my_gawd.
If you're curious, it's in /arch/mips/pci/ops-bridge.c.

There's another where someone drew clouds and I think cows and space ships(??) in ascii art. I can't remember which file it is in though, and it's a lot harder to grep for. I'm pretty sure it's over in the networking portion of the kernel though.

This is another nice one, but it includes source;

/* Oh yes, the MIF BitBang is mighty fun to program.  BitBucket is more like it. */
static void BB_PUT_BIT(struct happy_meal *hp, void __iomem *tregs, int bit)
{
    hme_write32(hp, tregs + TCVR_BBDATA, bit);
    hme_write32(hp, tregs + TCVR_BBCLOCK, 0);
    hme_write32(hp, tregs + TCVR_BBCLOCK, 1);
}

Have to love that struct name :). From /drivers/net/ethernet/sun

I'll leave here. The kernel is a goldmine of hilarious, and maybe slightly frightening, comments and humour.

Collapse
 
yechielk profile image
Yechiel Kalmenson

I added my contact info and my picture in ASCII art to my personal site (as well as some of my side projects).

You might have to step away from the screen and squint in just the right way, but that's me :)

me in ascii art

Collapse
 
pilskalns profile image
Andžs

Once I had to take over Android app code from outsourced dev, where still I can't code anything myself.

Lurked through code and found exception handler...

try {
...code of something very very important...
} catch (Exception e) {
// Meh...
}

Collapse
 
jordanroskelley profile image
Jordan Roskelley • Edited

I'm a realist, and I know that I'm probably the one who will be looking at my comments next... so I like to leave myself nice notes, things like: "Dear future self, it looks like you ended up here (again), this is probably because [bad data situation]. Check that first. Good luck, Love - self, on [date]

Collapse
 
nelruk profile image
Nelson

You're so cute with yourself.. :)

Collapse
 
ranelpadon profile image
ranelpadon • Edited

Sevilla FC is one of the top football clubs in Spain and its website markup contains the club's ASCII logo.
Sevilla FC logo

Collapse
 
mureke profile image
Markus • Edited

This one I found from the website of a finnish company called Reaktor.

Reaktor comment

Collapse
 
victoria profile image
Victoria Drake

Going through my old "top posts" emails and saw this... just thought I'd leave this here for anyone wanting to put a bit of fun in their source code: ascii.today/

:)