| I see what you're saying. Unfortunately that's not the only problem with monads. Monads have two problems: - They're explained badly. - Once they're explained well, many (including me) think it's a bad idea (not the monad, the motivation behind its use in pure-FP). You start with a pure functional formalism, because you like to be stateless. Then you realize that avoiding statefulness is impossible in computing. So you try to shoehorn state into your stateless state of affairs (no pun), while at the same time refusing to admit that you're not stateless anymore. The larger issue: some folks appear to think that imperativity is a subset of declarativity. What that really means is that, they're saying that, computing is a proper subset of math. And by that, what they're really saying, is that actions are a subset of words. In other words, if you write something on a piece of paper that describes some action in the real world, (roughly speaking) that action happens or is supposed to happen automatically. That's now how the world works. That's not how computers work. And I'm sorry to say that's not how programming works. Computing is not a subset of mathematics. And Mathematics is not a subset of Computing. Same goes with Physics (Physics is not a subset of Mathematics, despite there being way more math used in Physics than CS). Physics, Computing, and Mathematics are the holy trinity of the reality that we live in. You have to give each of the three the respect they deserve, and only try to make connections between the three, and NOT try to make any of them a subset of the other. |
if i understand you correctly, are you saying that mathematics in the classical sense is not “computing” (von neumann machines?), just as math is not physics, but math is used to model physics
then the proper way to think about the problem is: can there be a math that models actual computing (does that include physics?) as it is today, and is that what we already have in our programming languages today?
and finally, maybe your main point is, with purely functional languages, there is a math invented (lambda calculus?) to describe a stateless ideal that is shoehorned into a reality that it doesn’t describe?
apologies for the random thoughts, just trying to grok everything ^_^