this post was submitted on 07 Oct 2025
171 points (90.9% liked)

Programmer Humor

28465 readers
1639 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 2 years ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] markz@suppo.fi 7 points 3 months ago (4 children)

Looks like there's just a private constructor and a public getter for the instance.

[–] bluGill@fedia.io -1 points 3 months ago (3 children)

With no indication of why we should think such a thing should be. Singletons are sometimes useful, but they are the wrong answer to your problems more often than the right one. Even where they are a good answer to your problem a class should rarely enforce its own singletonness.

[–] drolex@sopuli.xyz 1 points 3 months ago (1 children)

Please don't make me tap the Gang of Four's Design Patterns book

[–] Feyd@programming.dev 5 points 3 months ago

That book did immeasurable damage to the software industry

load more comments (1 replies)
load more comments (1 replies)