all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Chong Yidong <cyd@stupidchicken.com>
To: Paul Nienaber <phox@phox.ca>
Cc: 3226@emacsbugs.donarmstrong.com
Subject: bug#3226: here-document syntax inference and completion is broken
Date: Sun, 16 Aug 2009 10:09:08 -0400	[thread overview]
Message-ID: <87ab1z26m3.fsf@cyd.mit.edu> (raw)

> Cook yourself up a bash script and type a line of code like:
> for i in $(/bin/vim <<
>
> A default emacs install will complete with "EOF\n\nEOF" (in a more
>clever fashion so the rest of the line is undisturbed), and place the
>cursor on the new blank line.  This is incorrect behaviour, as it
>breaks entry of BASH here-strings when the user's intent is still
>ambiguous.  This should only respond to things ending in, for example
>"<< " or possibly "<<E", but certainly NOT just "<<".
>
> Further, emacs does something outright wrong: An attempt to fix the
>situation by inserting another '<' between the "<<" and "EOF" +results
>in ANOTHER pair of "EOF" being inserted in a syntactically invalid way.

I fixed the second problem, but I don't see any easy way to solve the
first one.

(The difficulty of fixing the first bug is illustrative of the problems
with individual major modes rolling their own "electric" completion
facilities.  It might be nice to have a minor mode that provides a
unified framework for this kind of functionality; which may also need
built-in support.)





             reply	other threads:[~2009-08-16 14:09 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-16 14:09 Chong Yidong [this message]
2016-01-26  5:15 ` bug#3226: here-document syntax inference and completion is broken Andrew Hyatt
2016-02-14 14:44   ` Philipp Stephani
2016-03-27 19:56     ` Mark Oteiza
2016-03-27 22:43       ` Stefan Monnier
2016-04-16 18:49         ` Mark Oteiza
  -- strict thread matches above, loose matches on Subject: below --
2009-05-05 22:15 Paul Nienaber
2009-05-06  3:36 ` Stefan Monnier
2019-10-11 19:38   ` Lars Ingebrigtsen
2019-10-15 22:09     ` Paul Nienaber
2019-10-16  1:40       ` Lars Ingebrigtsen
2019-10-16  6:04         ` Paul Nienaber
2019-10-16  7:20           ` Lars Ingebrigtsen
2019-10-16 12:43         ` Stefan Monnier

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=87ab1z26m3.fsf@cyd.mit.edu \
    --to=cyd@stupidchicken.com \
    --cc=3226@emacsbugs.donarmstrong.com \
    --cc=phox@phox.ca \
    /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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.