From: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: emacs-devel@gnu.org
Subject: Re: perl-mode "::" as word character [patch]
Date: Sun, 01 May 2005 12:44:03 -0400 [thread overview]
Message-ID: <m1vf623nkq.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <427329F6.5080508@pacbell.net> (Pandora's message of "Fri, 29 Apr 2005 23:47:18 -0700")
> Just dropping in for a teeny bit. I was studying font-lock innards the
> other day and noticed that the perl-mode font lock does a lot of
> wrangling around the '::' sequence. That's what's used in perl to
> divide package names from package members. But instead of sticking
> \\(::\\sw\\)*s in after every \\sw, I noticed it'd be much simpler just
> to consider the double colon (NOT the single colon) to be a \\sw
> character. Seems pretty cut and dried, since :: was only introduced to
> perl as a namespace separator, and can be wholly considered as if it
> were a word character.
Word syntax is clearly wrong. Symbol syntax (i.e. "_") OTOH sounds right.
> Also since my experience has been that print/printf are used like
> keywords, but act like functions; they could use some special
> highlighting. As for functions in general, both &\\(\\sw+\\) and
> \\(\\sw+\\)( match a function name in perl, but perl-mode only
> highlights the first expression as a function.
I don't think function calls should be highlighted, only function definitions.
But that's just me.
Could you (re)send a context diff rather than plain diff?
Stefan
next prev parent reply other threads:[~2005-05-01 16:44 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-04-30 6:47 perl-mode "::" as word character [patch] Pandora
2005-05-01 16:44 ` Stefan Monnier [this message]
2005-05-06 1:19 ` Pandora
2005-05-06 3:02 ` 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=m1vf623nkq.fsf-monnier+emacs@gnu.org \
--to=monnier@iro.umontreal.ca \
--cc=emacs-devel@gnu.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 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.