zsh-workers
 help / color / mirror / code / Atom feed
From: Martijn Dekker <martijn@inlv.org>
To: Zsh hackers list <zsh-workers@zsh.org>
Subject: $((++a++))
Date: Mon, 4 Sep 2017 22:45:46 +0200	[thread overview]
Message-ID: <74d2c8e3-7a0f-b705-29c8-e5a2f6e182aa@inlv.org> (raw)

Why is this accepted?

% a=1
% echo $((++a++))
2
% echo $((--a--))
1

Looks like that should be an invalid arithmetic expression.

- M.


             reply	other threads:[~2017-09-04 21:05 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20170904210547epcas2p2e46e1cb14a26b8e5fdd9217c58c077ff@epcas2p2.samsung.com>
2017-09-04 20:45 ` Martijn Dekker [this message]
2017-09-05 10:01   ` $((++a++)) Peter Stephenson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=74d2c8e3-7a0f-b705-29c8-e5a2f6e182aa@inlv.org \
    --to=martijn@inlv.org \
    --cc=zsh-workers@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).