Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  nodelist  faq  login

Steal my cash, car and TV - but leave the computer! -- Soenke Lange <soenke@escher.north.de>


programming / comp.lang.tcl / Re: incr result with non-var argument

SubjectAuthor
* incr result with non-var argumentOleg Nemanov
+- Re: incr result with non-var argumentOleg Nemanov
`* Re: incr result with non-var argumentAlan Grunwald
 `- Re: incr result with non-var argumentAlan Grunwald

1
Subject: incr result with non-var argument
From: Oleg Nemanov
Newsgroups: comp.lang.tcl
Date: Fri, 22 Apr 2022 11:44 UTC
X-Received: by 2002:a05:6214:d85:b0:449:96f7:6194 with SMTP id e5-20020a0562140d8500b0044996f76194mr3193012qve.48.1650627899790;
Fri, 22 Apr 2022 04:44:59 -0700 (PDT)
X-Received: by 2002:a05:6870:a707:b0:e2:cc85:d98 with SMTP id
g7-20020a056870a70700b000e2cc850d98mr5844626oam.131.1650627899478; Fri, 22
Apr 2022 04:44:59 -0700 (PDT)
Path: i2pn2.org!i2pn.org!usenet.goja.nl.eu.org!3.eu.feeder.erje.net!feeder.erje.net!proxad.net!feeder1-2.proxad.net!209.85.160.216.MISMATCH!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.tcl
Date: Fri, 22 Apr 2022 04:44:59 -0700 (PDT)
Injection-Info: google-groups.googlegroups.com; posting-host=194.190.114.28; posting-account=RPJNegoAAAAUgD_yLdrci9D1ZtZ1oI0L
NNTP-Posting-Host: 194.190.114.28
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <f7c013ad-92af-4033-960d-1daeacbb05afn@googlegroups.com>
Subject: incr result with non-var argument
From: oleg.o.n...@gmail.com (Oleg Nemanov)
Injection-Date: Fri, 22 Apr 2022 11:44:59 +0000
Content-Type: text/plain; charset="UTF-8"
View all headers
Hi, all.

Why incr return a sequence of numbers in this case:

% set a [dict create k 22]
k 22
% incr [dict get $a k]
1
% incr [dict get $a k]
2
% incr [dict get $a k]
3
% incr [dict get $a k]
4
% puts $a
k 22


Subject: Re: incr result with non-var argument
From: Oleg Nemanov
Newsgroups: comp.lang.tcl
Date: Fri, 22 Apr 2022 11:48 UTC
References: 1
X-Received: by 2002:a05:6214:c64:b0:449:7011:569d with SMTP id t4-20020a0562140c6400b004497011569dmr2892279qvj.90.1650628105605;
Fri, 22 Apr 2022 04:48:25 -0700 (PDT)
X-Received: by 2002:a9d:2949:0:b0:605:4b9b:6422 with SMTP id
d67-20020a9d2949000000b006054b9b6422mr1516003otb.378.1650628105351; Fri, 22
Apr 2022 04:48:25 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!1.us.feeder.erje.net!feeder.erje.net!border1.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.tcl
Date: Fri, 22 Apr 2022 04:48:25 -0700 (PDT)
In-Reply-To: <f7c013ad-92af-4033-960d-1daeacbb05afn@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=194.190.114.28; posting-account=RPJNegoAAAAUgD_yLdrci9D1ZtZ1oI0L
NNTP-Posting-Host: 194.190.114.28
References: <f7c013ad-92af-4033-960d-1daeacbb05afn@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <e2410dea-d2e0-4ee4-9e30-3270e69511b0n@googlegroups.com>
Subject: Re: incr result with non-var argument
From: oleg.o.n...@gmail.com (Oleg Nemanov)
Injection-Date: Fri, 22 Apr 2022 11:48:25 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Lines: 19
View all headers
пятница, 22 апреля 2022 г. в 14:45:02 UTC+3, Oleg Nemanov:
Hi, all.

Why incr return a sequence of numbers in this case:

% set a [dict create k 22]
k 22
% incr [dict get $a k]
1
% incr [dict get $a k]
2
% incr [dict get $a k]
3
% incr [dict get $a k]
4
% puts $a
k 22

:-D I understood. Because incr increment a variable with name '22'.


Subject: Re: incr result with non-var argument
From: Alan Grunwald
Newsgroups: comp.lang.tcl
Organization: A noiseless patient Spider
Date: Fri, 22 Apr 2022 18:57 UTC
References: 1
Path: i2pn2.org!i2pn.org!eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail
From: nospam.n...@gmail.com (Alan Grunwald)
Newsgroups: comp.lang.tcl
Subject: Re: incr result with non-var argument
Date: Fri, 22 Apr 2022 19:57:29 +0100
Organization: A noiseless patient Spider
Lines: 25
Message-ID: <t3utqp$kvv$1@dont-email.me>
References: <f7c013ad-92af-4033-960d-1daeacbb05afn@googlegroups.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Fri, 22 Apr 2022 18:57:29 -0000 (UTC)
Injection-Info: reader02.eternal-september.org; posting-host="3458781eb2a798ebf8f9d04d5457d81d";
logging-data="21503"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/l5c1LOCiUfIZ22CpwohamtgorWGaHjds="
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101
Thunderbird/91.7.0
Cancel-Lock: sha1:2KEcZ1YtO8ym7jqK/3Y4YUUF2tM=
In-Reply-To: <f7c013ad-92af-4033-960d-1daeacbb05afn@googlegroups.com>
Content-Language: en-US
View all headers
On 22/04/2022 12:44, Oleg Nemanov wrote:
Hi, all.

Why incr return a sequence of numbers in this case:

% set a [dict create k 22]
k 22
% incr [dict get $a k]
1
% incr [dict get $a k]
2
% incr [dict get $a k]
3
% incr [dict get $a k]
4
% puts $a
k 22

Evaluate

set 22

Does that help explain what's happening?

Alan


Subject: Re: incr result with non-var argument
From: Alan Grunwald
Newsgroups: comp.lang.tcl
Organization: A noiseless patient Spider
Date: Fri, 22 Apr 2022 19:00 UTC
References: 1 2
Path: i2pn2.org!i2pn.org!eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail
From: nospam.n...@gmail.com (Alan Grunwald)
Newsgroups: comp.lang.tcl
Subject: Re: incr result with non-var argument
Date: Fri, 22 Apr 2022 20:00:56 +0100
Organization: A noiseless patient Spider
Lines: 30
Message-ID: <t3uu18$kvv$2@dont-email.me>
References: <f7c013ad-92af-4033-960d-1daeacbb05afn@googlegroups.com>
<t3utqp$kvv$1@dont-email.me>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Fri, 22 Apr 2022 19:00:56 -0000 (UTC)
Injection-Info: reader02.eternal-september.org; posting-host="3458781eb2a798ebf8f9d04d5457d81d";
logging-data="21503"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18CBEcfn8sWqBvz6bfbv8U4b9An1L69RAE="
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101
Thunderbird/91.7.0
Cancel-Lock: sha1:LU0EKv6NqQUF1ch4o9c6MK1uvmk=
In-Reply-To: <t3utqp$kvv$1@dont-email.me>
Content-Language: en-US
View all headers
On 22/04/2022 19:57, Alan Grunwald wrote:
On 22/04/2022 12:44, Oleg Nemanov wrote:
Hi, all.

Why incr return a sequence of numbers in this case:

% set a [dict create k 22]
k 22
% incr [dict get $a k]
1
% incr [dict get $a k]
2
% incr [dict get $a k]
3
% incr [dict get $a k]
4
% puts $a
k 22

Evaluate

set 22

Does that help explain what's happening?

Alan

Sorry. I must remember to read the whole thread before I follow up.

Alan


1
rocksolid light 0.7.2
clearneti2ptor