Treating your program as a black box with set of inputs and outputs to avoid library reliance is useful. As mentioned, it increases portability, eases maintenance and future revision. One downside however might be not taking full advantage of library implementation details for performance concerns. Anyway, this sounds like a case for building for interfaces or abstractions, and the same arguments apply. I would agree though that this is a good approach to take in general.
2 comments
[ 5.2 ms ] story [ 14.2 ms ] threadThen I tried it with Clojure, even though I don't have to, and it seemed a lot simpler. Just pass a map around with all the data in it, or whatever.