From: David Hansen <david.hansen@gmx.net>
Subject: Re: char syntax of the $ in $var
Date: Wed, 23 Mar 2005 01:43:32 +0100 [thread overview]
Message-ID: <87k6nz2nuz.fsf@robotron.ath.cx> (raw)
In-Reply-To: fc339e4a050322160571207726@mail.gmail.com
On Wed, 23 Mar 2005 09:05:18 +0900 Miles Bader wrote:
> On Wed, 23 Mar 2005 00:03:51 +0100, David Hansen wrote:
>> in sh-mode: the $ in $test has syntax 2 = word in perl-mode
>> syntax 10 = character quote and in cperl-mode it's 9 = escape.
>>
> In sh, the $ is not really part of the name, so having emacs
> think it is can be quite annoying (the case that drives me nuts
> is that dynamic-abbrev won't complete `$FO' based on a previous
> `FOO_BAR=...'); this argues for giving the $ a non-word syntax.
Sounds reasonable.
> In perl, on the other hand, the $ is treated much more as if
> it's actually part of the variable name (e.g., you write `$foo
> = 3'), so giving the $ word syntax might the right thing to do
> for perl.
You'll run into the same completion problems with e.g %foo and
$foo{'bar'}. So probably all non-word syntax...
David
next prev parent reply other threads:[~2005-03-23 0:43 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-03-22 23:03 char syntax of the $ in $var David Hansen
2005-03-23 0:05 ` Miles Bader
2005-03-23 0:43 ` David Hansen [this message]
2005-03-23 9:57 ` Kim F. Storm
2005-03-23 13:27 ` Stefan
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87k6nz2nuz.fsf@robotron.ath.cx \
--to=david.hansen@gmx.net \
/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.savannah.gnu.org/cgit/emacs.git
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 read-only IMAP folder(s) and NNTP newsgroup(s).