r/ProgrammerHumor • • 6d ago

Meme technicallyItCompiles

Post image
876 Upvotes

23 comments sorted by

61

u/JackNotOLantern 6d ago

> crash occurs
> array out of bounds
> look at the code
> on the line it happens there is a warning
> "may cause array out of bounds"

25

u/gooseears 6d ago

Let me just comment that warning out. Should be fine now.

6

u/Some_Useless_Person 6d ago

Wait what? How do you comment a warning?

7

u/5up3rj 6d ago

The IDE settings are a pathway to many abilities

5

u/JackNotOLantern 6d ago

Ide settings or something like in java "@SuppressWarning(...)"

3

u/metaglot 6d ago

Yeah. Warnings are errors waiting to happen at runtime.

2

u/TheWashbear 5d ago

pragma warning disable

See? No more warning, everything is fixed. This conversation may have been happened to me with a trainee

19

u/RandomStranger456123 6d ago

My favorite part is how our code we maintain has no warnings, but the framework we are required by our contract to use has over 23000.

2

u/ChChChillian 2d ago

Which is largely why I ignore them.

6

u/F_P_G_A 6d ago

Multiply by 10 for FPGA compilers

5

u/sardonicus87 5d ago edited 5d ago

To be fair, half of them are bs.

"Weak warning, use destructuring declaration..."

Except this:

for (i in Items) {
    i.prop
    i.something
    // like 10 more things
}

Looks way better than:

for ((prop, something, another, another1, yetAnother, andAnother, andAnother, etcToTenFnThings) in Items) {
    prop
    something
    // etc.
}

Like yeah, sometimes destructuring makes sense, but not always. Like at least 75% of the lint is warnings for dumb crap. @Suppress("Stupid Warning") everywhere, which wouldn't be necessary if the IDE would stop turning back on randomly all the dumb lint warnings after I turned them off 1,000 different times.

1,000 warnings and 980 of them are "style issues". Like, gtfo.

4

u/menducoide 6d ago

tech debt master class

4

u/emetcalf 6d ago

Warnings are like speed limits, just ignore them.

3

u/Some_Useless_Person 6d ago

Almost every C project ever

3

u/Johanno1 6d ago

Hey guys try to build the AOSP. It has over several million warnings. I think they can be safely ignored

2

u/Flaky-Low-2262 6d ago

Everyone: We finally need time to Test and houseeking over freeze Xmas Sprint...
PO: Compiles? LGTM! Thats like test Coverage of 100%

1

u/GogglesPisano 2d ago

It compiles! That means every line of code is tested!

2

u/oalfonso 6d ago

2026: SCA stage in the pipeline reports 1387 critical CVEs

2

u/Ved_s 5d ago

#![deny(warnings)]

2

u/whackylabs 5d ago

Hello -Werror

2

u/FoodBorn2284 4d ago

How it feels to maintain an ANSI C codebase (real)

1

u/Aethir300 2d ago

Meanwhile Vivado gives 10,000 warnings when you open it lol. FPGA tools are hilarious