Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Variable fails to increment with lvalue error
- X-seq: zsh-users 29314
- From: Dominik Vogt <dominik.vogt@xxxxxx>
- To: zsh-users@xxxxxxx
- Subject: Re: Variable fails to increment with lvalue error
- Date: Mon, 23 Oct 2023 17:34:24 +0100
- Archived-at: <https://zsh.org/users/29314>
- In-reply-to: <F6518D8B-3EE2-4552-89CA-035CD50226A3@gmail.com>
- List-id: <zsh-users.zsh.org>
- Mail-followup-to: zsh-users@xxxxxxx
- References: <F6518D8B-3EE2-4552-89CA-035CD50226A3@gmail.com>
- Reply-to: zsh-users@xxxxxxx
- Ui-outboundreport: notjunk:1;M01:P0:cmNOGEftTiY=;Hyq84KrKIe6TXu5jjRzGcSwRlgR n+y/JRIstm4gN5EcBegXhJSzNVvBjprVMI+hGMD2NBuLDBo7HI+jufKVMveAgz4bEyb0+IHMI qImpoccS+FaJet4ZXAxoFljCJ/7fUoCgLv/iCMbmtfmrWgJjmNo1Fm/VTlawOmeD39AYSKe4V W5XVwELuporr5XAxs5Bu4aCMYLsLmdNApQNjAR/DwqNw0g7lc8DXgpbhJpwuLPPZ4Gsgagvwg eBZ4Pf+dMpUiq5eptXDflZpJzIDP3KZ2zo7Qfxkc/z26APAA3cm18Y1XUKADvPoORiGIaBnPK WykIF4vsS8Cthkr9M1PfDz/I52EnIFJttMD86E1uAALiBTTLj1a13uodoqZWCix2N/DSDzHIT 1UileLpO0phJtGt/V82XTzGNvOKxr8X9Yt8pn8eOy2myMQ659NipWSLmo+Z4HN7DP6qJM7w4L LfFbwDnM4H7l4USOUoUtNscYtRQY8Q04R5JP8qC/heiD6AbpBBZpPFd6S1gtfF/Yx23s3NJKI gL5j8K2lxl79iyH0/5TzbteUwYhF1pftAPUc6YDQuuv9MFfQnyQZKkptwEh1Thmyfkh0gh23x vTueDXrQBw0NBX1uCkXMaMBUxZr7H7087oRVOaeHfeKnAm7MJuFmZHDGV9glSWHZdb14KeCbA S2z0UcBD6Kn7qKbQk85zNFNvZoTWIWzK+93Ygk71zQG8fHmxTrnOsegQdl9MWXERYdfX8fDMf So3XoYYMBMMzXBuvLbaqJVCwUlDE6qXyOPOwJSnOnCsZzKrnArjF699a3DmIg1EADnx9QjbXI z7MniJjNhQemk7gpgysE0jmLXfPRpGQngPn2GI+wICOfYDfP5fVV19MaNWk+4MF0VgKvtwOML 0qAyvDr7GCAf1WCi61HIMvHDb8X5KSXBhZmPwxveq87SvoQCOP9j5CeLLT7h6UiU8uwa22EuU aLeg+0eUhsOlOhvLNUy/8CcIqkw=
On Mon, Oct 23, 2023 at 11:27:50AM -0400, Evan Clearfield wrote:
> initialized my variable outside the loop, such that ???count=0???.
> I then increment it with a simple call ???(($count++))???, and
> when I run the script, I receive the error ???bad math expression:
> lvalue required???
Use ((count++)) instead of (($count++)).
Ciao
Dominik ^_^ ^_^
--
Dominik Vogt
Messages sorted by:
Reverse Date,
Date,
Thread,
Author