All of lore.kernel.org
 help / color / mirror / Atom feed
From: Petr Baudis <pasky@suse.cz>
To: Avery Pennarun <apenwarr@gmail.com>
Cc: gitster@pobox.com, git@vger.kernel.org
Subject: Re: [PATCH] Add Pascal/Delphi (.pas file) funcname pattern.
Date: Fri, 1 Aug 2008 22:20:59 +0200	[thread overview]
Message-ID: <20080801202059.GS32184@machine.or.cz> (raw)
In-Reply-To: <1217619915-9331-1-git-send-email-apenwarr@gmail.com>

On Fri, Aug 01, 2008 at 03:45:15PM -0400, Avery Pennarun wrote:
> diff --git a/diff.c b/diff.c
> index cbf2547..c73ba69 100644
> --- a/diff.c
> +++ b/diff.c
> @@ -1380,6 +1380,10 @@ static struct builtin_funcname_pattern {
>  			"^[ 	]*\\(\\([ 	]*"
>  			"[A-Za-z_][A-Za-z_0-9]*\\)\\{2,\\}"
>  			"[ 	]*([^;]*\\)$" },
> +	{ "pas", "\\(^\\(procedure\\|function\\|constructor\\|"
> +			"destructor\\|interface\\|implementation\\|"
> +			"type|initialization|finalization\\).*$\\)"
> +			"\\|\\(^.*=[ \t]*\\(class\\|record\\).*$\\)" },
>  	{ "tex", "^\\(\\\\\\(sub\\)*section{.*\\)$" },
>  };
>  

Wouldn't it be better to make the second pattern start on new line
instead of the outer \(\|\)?

Why "type"?

-- 
		Petr "Pasky, but not writing in Pascal anymore!" Baudis
As in certain cults it is possible to kill a process if you know
its true name.  -- Ken Thompson and Dennis M. Ritchie

  parent reply	other threads:[~2008-08-01 20:22 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-01 19:45 [PATCH] Add Pascal/Delphi (.pas file) funcname pattern Avery Pennarun
2008-08-01 20:16 ` Junio C Hamano
2008-08-01 20:38   ` Avery Pennarun
2008-08-01 20:20 ` Petr Baudis [this message]
2008-08-01 20:40   ` Avery Pennarun
  -- strict thread matches above, loose matches on Subject: below --
2008-08-01 21:00 Avery Pennarun

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=20080801202059.GS32184@machine.or.cz \
    --to=pasky@suse.cz \
    --cc=apenwarr@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    /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.
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.