3 ms·
>Problem with OOP + Types is that it requires you predict future No, they don't? They let you scope things safely, in context and with meaning attached. If you
by thecupisblue 6y ago
>Problem with OOP + Types is that it requires you predict future
No, they don't? They let you scope things safely, in context and with meaning attached. If you try to "predict the future", that's your problem.
> and come with convoluted interdependent structure that forever binds your code
What are you even talking about?
Nobody is forcing you to write it like that. You are writing it like that. You can write functional monad hell in a bad way just as you can create super convoluted structures that seep through your codebase. It isn't the fault of a programming paradigm, it's your fault.
> Had you been using modular functions in dynamically typed language you'd have to simply update one single function and be on your way
Really? Because you never had to update something throughout multiple functions? Because if you write "modular functions" the requirements never change and you can predict the future with 100% certainty?
>Every time you create a type, you create dependency into the entire code, everywhere that type is used.
And every time you create a function, you create a dependency everywhere that function is used.
>World can't be modeled in single inheritance and future can't be predicted with 100% certainty.
Did anyone say that? Ever?
What you are saying is "oil paint is better than acrylics in any way, the world doesn't dry after a minute! The world is changing!". Or "Screwdrivers are better than wrenches! Wrenches are evil!".
Yes, if you don't know how to use a wrench, you might hit yourself on the fingers with it. It's not the wrenches fault.
Instead of being so frustrated at a paradigm, grow up and accept that programming is not a single-track single-minded single-person single-paradigm job. You keep acting like the only way to use types is to shoehorn everything into a type and an object that inherits something. Or that everyone builds out huge complicated FactoryAdapterMapperBuilderCreatorBeans that do who-knows-what. It's not types, it's just bad code.
Instead of wasting your time on trying to wage a holy war of paradigms, go outside and take a breathe of fresh air. It's better for you.