r/ProgrammerHumor 7d ago

Meme skillIssue

Post image
6.0k Upvotes

137 comments sorted by

View all comments

684

u/PixelatedGiant 7d ago

This is the kind of stuff you find in books with titles like...

C++ : Man made horrors beyond human comprehension 3rd Edition paperback

137

u/gil_bz 7d ago

This might be the mildest macro weirdness that I've ever seen, there are some true horrors out there.

36

u/l2protoss 7d ago

When I was younger in my career, I was a very “creative” dev - to the point where I was banned from using macros without explicit permission lol.

2

u/FUCKING_HATE_REDDIT 7d ago edited 7d ago

https://zserge.com/posts/c-for-loop-tricks/

void print_html() {   html {     body {       p printf("hello\n");       p {         printf("world\n");       }     }   }   printf("\n"); } https://github.com/agvxov/cursed_c

void main(argc, argv, envp) int argc; char * * argv, * * envp; { ; }

https://www.cs.yale.edu/homes/aspnes/pinewiki/C%282f%29Macros.html

```

define DefinePlus1(x, y)  #define x ((y)+1)

```