[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Are variables immutable?
- From: Lars Müller <appgurulars@...>
- Date: Wed, 25 May 2022 18:38:32 +0200
In fact it changes the environment table: myName = something is
equivalent to _ENV["myName"] = something
Local variables work similarly: local myName = something; myName =
something_else doesn't change the value something, it changes the
contents of the variable myName, which is basically a
"pointer"/"reference" to a value.
On 25.05.22 18:35, Duke Normandin wrote:
On Wed, 25 May 2022 11:11:42 -0500
Javier Guerra Giraldez <email@example.com> wrote:
when you change myName, it changes the variable, not the value.
That does NOT make sense to me! The variable name, i.e. myName is
not changed. The contents of variable myName has been changed to
I get it that 'blah' and 'blah-blau' are 2 different strings and
are set in stone. But I don't see the point of even bringing the
subject of string immutability unless it's in the context of they
** Text only please. Bottom post works best for me **