🧠 Engineering Culture

OCP's Big Lie: Stop Guessing the Future

Open-Closed Principle? It's not about psychic coding. Jon Skeet calls BS on the hype—time to rethink how you build extensible Swift without the guilt.

Diagram showing bad vs good OCP implementation in Swift code with protocols

⚡ Key Takeaways

  • OCP isn't "no modifications ever"—it's about stable boundaries for changes.
  • Use protocols in Swift to isolate variations like payments or shapes.
  • Protected Variations beats OCP wording; predict real, current flux.
Published by

DevTools Feed

Ship faster. Build smarter.

Worth sharing?

Get the best Developer Tools stories of the week in your inbox — no noise, no spam.

Originally reported by dev.to

Stay in the loop

The week's most important stories from DevTools Feed, delivered once a week.