zsh-workers
 help / color / mirror / code / Atom feed
From: "Richard Hartmann" <richih.mailinglist@gmail.com>
To: "Zsh hackers list" <zsh-workers@sunsite.dk>
Subject: Strange parsing bug(?)
Date: Wed, 1 Oct 2008 02:56:39 +0200	[thread overview]
Message-ID: <2d460de70809301756j71effaa9waa6b1a1d0736d9b9@mail.gmail.com> (raw)

Hi all,

I have stumbled upon a really weird bug. Due to it being late & me
being ill, I thought I did something wrong, but I pruned a rather
long & complex part of my zshrc down do this:

  echo "!"

The evil part is that a warning was part of a really deep & broad
boolean expression which made me assume I did something wrong
when the interactive parser failed to do what I wanted.

Frustrating when you find the actual cause after several hours :p

I suspect it's history access/modification gone awry because of
the exclamation mark and the fact that only interactive use is
affected, but I am not sure. Stuff in <brackets> are key presses,
the # is an 'inline' comment:

richih@roadwarrior ~ % zsh -f
roadwarrior% echo 'echo "!"' > temp
roadwarrior% source temp
!
roadwarrior% echo "!"
dquote> <Enter>
dquote> <CTRL-C>
roadwarrior% <UP>
roadwarrior% echo "
<CTRL-C> # there is a blank line, here. Cursor is at the left
roadwarrior% echo "!""

roadwarrior%


Of course, I might have stumbled onto a hidden feature, but if that
is the case, I would argue that this is extremely against the
expectation of most users.


Richard


             reply	other threads:[~2008-10-01  0:58 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-01  0:56 Richard Hartmann [this message]
2008-10-01  1:05 ` Richard Hartmann
2008-10-01  6:06 ` Bart Schaefer
2008-10-01  7:36   ` Richard Hartmann

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=2d460de70809301756j71effaa9waa6b1a1d0736d9b9@mail.gmail.com \
    --to=richih.mailinglist@gmail.com \
    --cc=zsh-workers@sunsite.dk \
    /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).