4 ms·
Magic is of course a very arbitrary word: I'll define it more specifically as: It represents things that happen that you don't understand how they happen. Not
by AtlasBarfed 5y ago
Magic is of course a very arbitrary word: I'll define it more specifically as:
It represents things that happen that you don't understand how they happen. Not just you don't understand how they work when presented with the effect, but is resistant to being reverse-engineered.
In your typical programming environment there are ways to backtrack through code searches, type hierarchy management/overloads, interface implementations, type definitions, recasts, scope resolution, etc that you can deconstruct some "magic incantation" to figure out where it is calling and then what it is doing.
In dynamic languages (the article is about Ruby) this gets a lot more dicey, with duck typing, lack of strong typing or optional typing to enforce / document what types are being used where, sometimes dynamic scoping, macro expansions.
In those cases, IDEs are you friend in a BIG BIG way. They enable targetting searches, parsed/contextual navigations, type guessing even for some dynamic languages. IDE+static-ish typed languages is even better: back navigation to the type, navigate up the type hierarchies or compositions.