5 ms·
> Only a functional programmer would think that recreating the entire universe is necessary to change a value. That's wrong. You can't change a value at all. W
by catnaroek 10y ago
> Only a functional programmer would think that recreating the entire universe is necessary to change a value.
That's wrong. You can't change a value at all. What you can change is the state of an object. And functional languages have mutable objects too:
https://docs.microsoft.com/en-us/dotnet/articles/fsharp/language-reference/reference-cells https://docs.microsoft.com/en-us/dotnet/articles/fsharp/lang...
http://hackage.haskell.org/package/base-4.9.0.0/docs/Data-IORef.html http://hackage.haskell.org/package/base-4.9.0.0/docs/Data-IO...
- jdmichal 10y agoIt wasn't meant to be correct... That's the whole point. "What we've got here, is a failure to communicate." Your definition of a "value" seems to be a strictly immutable, functional-oriented definition. Which is fine; that's a valid definition and there's nothing wrong with it. The issues come from the fact that you seem to refuse to accept that that is one definition of many, and continue to push it without compromise.
- catnaroek 10y agoThe difference is that what I said was actually correct.
- jdmichal 10y agoIt's correct only using your definitions and axioms. Other definitions and axioms can and do come to other conclusions. Your refusal to acknowledge that other definitions and axioms even exist is what is earning you the ire you are experiencing.
- catnaroek 10y ago> Your definition of a "value" seems to be a strictly immutable, functional-oriented definition. The very question of mutability only makes sense for objects that reside in computer memory. Asking whether values mutate is as meaningless as asking what the color of your feelings is. > the ire you are experiencing. I'm deliberately provoking it.
- jdmichal 10y ago> I'm deliberately provoking it. I'll just start flagging you for trolling then. It's one thing to attempt to have a meaningful discussion and unintentionally provoke ire. Meaningfully doing it by being obtuse and smug... I guess qwerty was spot on with the Randall Monroe quote.
- catnaroek 10y ago> Meaningfully doing it by being obtuse and smug... I don't think I was being obtuse. I just expected (in the statistical sense of the term “expectation”) the reaction I got, and decided that it don't mind it.
- qwertyuiop924 10y ago...And that should have taught you something: it should have taught you that the language you're using isn't being readily understood, and that you need to either explain it, or change it.
- Bjartr 10y agoWhy do you not mind being poorly understood? The goal of effective communication is to have others understand you. Since you're not trying to communicate effectively, what exactly is it that you think you are doing?
- catnaroek 10y ago> Why do you not mind being poorly understood? What I said I didn't mind is the “ire you are experiencing”. It somewhat saddens me that programmers, supposedly logical thinkers, can't see the distinction between a value and an object. > Since you're not trying to communicate effectively, what exactly is it that you think you are doing? I'm pointing to the distinction between values and objects pretty clearly: (0) Objects exist in memory. Values exist in the language's semantics, not in computer memory, but representations of values exist in computer memory. Furthermore, objects exist in memory exactly once, but a value may be represented in memory any number of times. (1) It doesn't make sense to distinguish between representations of the same value. If a program treats two memory blobs differently, their contents represent different values, period. (The converse is not true, of course.) (2) The language implementation has absolute freedom to represent values as it wishes, as long as (1) isn't violated. But this isn't the first time I've said all of this in this thread.