3 ms·
As a simple example, suppose I swap out one container type with another one in the internal code. Both implement the same interface/traits, so the change isn't
by gmfawcett 9y ago
As a simple example, suppose I swap out one container type with another one in the internal code. Both implement the same interface/traits, so the change isn't visible to users. But the time complexity of the container operations are different on the new type, and the user was depending upon the time characteristics of the old container. E.g., deletions are now O(n) instead of O(1). I've violated a user expectation without breaking type safety.
- tome 9y agoNice counterexample!