3 ms·
I don't think that you deserve to be downvoted; you make an interesting point. Obviously an OS is a sort of framework; so too is a web server which calls one's
by zeveb 10y ago
I don't think that you deserve to be downvoted; you make an interesting point. Obviously an OS is a sort of framework; so too is a web server which calls one's code (I'll be honest, I don't quite get your point about compilers — can you elaborate?).
But good examples of both OSes & webservers offer pretty simple interfaces (I'm thinking of Plan 9 as an example of a good OS, and Go's http.Handler as an example of a decent HTTP interface). In both cases there's one entry point (a single designated function), with a reasonably well-defined API to query the environment in which it's called.
- marcosdumay 10y agoA compiler will also rewrite the entry point of your program, and probably just call your main() from another place. Yes, it's all about reasonable, documented and well defined APIs. If your framework has those, it won't get in your way. If you framework lacks those, it will get in your way with an intensity that libraries just can't match. But frameworks do not pose a completely new level of problems, your compiler, server or OS will create just as much trouble.