Does an author of a library have power over programmers?

Nov 12, 2016 13:28

The matter of programming with modules (which may be called “components”) (abstract data types is a related matter) is how to give a programmer access to a) some features of a module and b) not to give access to other features. Just for a reference, features (a) are an “interface”, and features (b) are an “implementation”. This means forbidding a programmer to use certain features in his/her program, in other words, forcing him/her to write his/her code in a certain way (usually, a way that contradicts library data invariants).

The issue that is easily overlooked is that here we leave the realm of programming, computer science, and mathematics, and enter the realm of law. Many programmers make, IMHO, a mistake here. An understandable mistake because they are not lawyers after all. (I am not a lawyer too.) They think that the author enforces something. I think that he/she does not. The only legal way of enforcing I can imagine is when the author offers his/her library under a license that states “If you use the library, you should respect invariants” and enforces this license by copyright. But I do not think any author is doing this in reality. And this makes sense: an author is not a boss of the programmers that use his/her library and does not want to be.

And now it is evident that a boss enforces this. So the author just provides a way for the boss to enforce, and this is achieved by a PL feature. By the same logic, the boss needs a way not to respect library data invariants, to use all functions of the library, and to construct and analyze any value of any data type that the library works with. Then the boss is free to give or not to give this power to his/her subordinate programmers. I think this is the reason why some PLs do not offer a way to enforce this: they respect boss’s rights. But a good PL should offer a way to force a specified set of programmers instead of a way to force everybody or not offering such a way.

computer science, information security, english, социальная сеть

Previous post Next post
Up