zsh-users
 help / color / mirror / code / Atom feed
From: Bart Schaefer <schaefer@brasslantern.com>
To: zsh-users@zsh.org
Subject: Re: bug in replace-string: widget loses characters
Date: Tue, 09 Oct 2012 08:24:25 -0700	[thread overview]
Message-ID: <121009082425.ZM29621@torch.brasslantern.com> (raw)
In-Reply-To: <CAECNH1RZuE0yh=bT2uVfUzQC0XtOy2abtbbihDCg3K0RDj8kcw@mail.gmail.com>

On Oct 9,  3:34pm, Peter Stephenson wrote:
}
} The one side effect is that $UNDO_CHANGE_NO is different each time it's
} read.  I could fix that if anyone cared, but if it helped you could sort
} of look on it as a feature: you are guaranteed that all recorded change
} points are unique and monotonically increasing whether or not the line
} itself was changed.

I think this is OK, but I suppose there might be a case where one wanted
to be able to detect whether any changes had occurred between state X
and state Y, e.g. previously

	local current_undo=$UNDO_CHANGE_NO
	# ... some stuff potentially happens ...
	if (( current_undo == UNDO_CHANGE_NO ))
	then
	  # nothing happened?
	fi

Is there another way to detect this?  It's probably not a common thing
to care about so perhaps not worth a lot of effort.


  reply	other threads:[~2012-10-09 15:24 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-08 18:19 Moritz Bunkus
2012-10-09 11:22 ` Peter Stephenson
2012-10-09 11:54   ` Moritz Bunkus
2012-10-09 14:34   ` Peter Stephenson
2012-10-09 15:24     ` Bart Schaefer [this message]
2012-10-09 15:44       ` Peter Stephenson
2012-10-09 16:11         ` 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=121009082425.ZM29621@torch.brasslantern.com \
    --to=schaefer@brasslantern.com \
    --cc=zsh-users@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).